W-009 · WIDGET

GitHub Stars

A GitHub stars widget displays the current star count, fork count, watcher count, and last-push timestamp of any public GitHub repository. WidgetCraft's GitHub Stars widget routes through our hosted proxy by default (no setup required), shows a star-delta pill when the count changes between polls, and embeds in Notion, Obsidian, or any iframe-capable website.

NotionObsidianAny website
HostPublic repos only — no login, no token, no setup needed
RefreshRefresh every ~5 minutes; star-delta pill compares against previous poll
https://widgetcraft.ai/w/github-stars?theme=light&accent=%23F06449
Customize in Builder

WidgetCraft's GitHub Stars widget is the fastest way to put a live repo stat badge inside a Notion page, an Obsidian vault, or a personal project site. Point it at any public repo with `?repo=owner/name` and it fetches star count, fork count, watcher count, open issue count, primary language, and last-push timestamp. By default the widget calls our hosted proxy at `/api/proxy/github`, which carries the operator's server-side GITHUB_TOKEN (5000 req/hr shared across all embeds) and caches upstream responses for 5 minutes — so ten users embedding the same repo don't burn ten times the budget. Between polls it compares the new star count to the cached value in localStorage and renders a green +N or red -N delta pill, giving you a real-time feel without webhooks. The compact layout option (`?layout=compact`) hides the secondary stats and description for tight spaces. Power users who want to use their own token (for private repos, or just to keep traffic off our quota) can pass `?token=ghp_...` with a fine-grained personal access token and the widget will call api.github.com directly. The default refresh cadence is every 5 minutes.

FAQ

Questions, answered.

Can I track any public repo?

Yes. Add `?repo=owner/reponame` to the embed URL — for example `?repo=vercel/next.js`. Any public GitHub repository works. Private repos require a token with the appropriate scope, but the widget will silently fail if the token lacks access.

What's the rate limit?

Our hosted proxy uses an operator-shared token with 5000 requests per hour, so the default path easily handles any refresh cadence you'd set. When self-hosting without a token, the fallback path calls GitHub unauthenticated (60 req/hr per IP), which is still plenty for a 5-minute refresh interval (12 calls per hour per widget).

Can I use a personal access token for higher limits?

Yes. Add `?token=ghp_yourtoken` to the embed URL to bypass our proxy and call api.github.com directly from the browser. The token is stored in the URL and sent as a Bearer header on each API request. Use a fine-grained token with read-only `public_repo` scope — never a token with write access.

What is the delta pill next to the star count?

Between polls the widget compares the latest star count to the value it stored locally on the previous load. If the number changed, it shows a green +N (gain) or red -N (loss) pill. The delta clears once a new poll returns the same count.

How often does the star count refresh?

Every 5 minutes by default. Set `?refresh=N` to change the interval in minutes. Values below 1 are ignored.

Does it show forks and open issues too?

Yes, in the full layout. The widget shows stars as the hero stat, then a row of chips for forks, watchers, and open issues below it. Switch to `?layout=compact` to show only the star count and last-push timestamp.

What happens if the repo doesn't exist?

The widget displays an error message: 'Repo not found: owner/name'. Double-check the slug format — it must be exactly `owner/reponame` with no leading slash.

Related widgets

W-018 · developer
Stocks
Stock price tracker — single ticker card, watchlist of multiple tickers, or hero-style big number. Mock data v1; live API integration coming with the Sora persona sprint.
W-001 · time
Clock
Time display in four visual variants — flip-board, analog watch, digital, or large minimal. 12 or 24 hour, optional seconds and date.
W-003 · weather
Weather
Current conditions and multi-day forecast. Automatic location detection.
Customize colors, fonts, and layout in the builder — preview live, copy the embed URL, paste anywhere.
Open in BuilderView all widgets