gh-widgets
Self-hosted SVG widgets for GitHub READMEs. gh-widgets is one Cloudflare Worker that renders header images, badges, and GitHub stats from options you pass in the URL. Your README never depends on someone else's image service.
Auto dark/light in a README
Wrap two image URLs in a <picture> tag and GitHub shows the one that matches
the viewer's theme. Every widget's builder generates this snippet for you.
<p align="center">
<picture>
<source media="(prefers-color-scheme: dark)"
srcset="https://gh-widgets.hdprajwal.dev/header/graph.svg?title=...&mode=dark" />
<img alt="my project"
src="https://gh-widgets.hdprajwal.dev/header/graph.svg?title=...&mode=light" />
</picture>
</p>
Run your own
You do not have to depend on this instance. gh-widgets is one worker with no database and no build secrets. Fork it and deploy your own copy on Cloudflare's free tier in a few minutes. Here is the full walkthrough.
Widgets
Routes follow /<widget>/<variant>.svg, so adding a new widget never
breaks an existing URL. Click a widget for examples, a builder, and its API reference.