Back to browse
GitDelivr: A free CDN for Git clones built on Cloudflare Workers and R2

GitDelivr: A free CDN for Git clones built on Cloudflare Workers and R2

by emirb·Mar 2, 2026·1 point·4 comments

AI Analysis

●●●BangerSolve My ProblemBig BrainSlick

Free Git CDN solves GNOME's bandwidth crisis; content-hash caching is clever.

Strengths
  • Solves a real, concrete pain point: GNOME spent cycles moving to GitHub mirrors to save bandwidth.
  • Content-addressable caching approach is genuinely clever—request body hash as cache key leverages Git's own immutability.
  • Zero trust model (Git verifies hashes client-side) removes security concerns that plague typical CDNs.
Weaknesses
  • No monetization or adoption metrics—unclear if this will outlive its initial launch moment.
  • Depends entirely on Cloudflare R2 availability and pricing; no portability to other backends.
Target Audience

Open source projects, large repos, anyone with high git clone bandwidth costs

Similar To

jsDelivr · Docker Hub CDN

Post Description

Hey HN...I built a free CDN to solve a real problem of slow or expensive git traffic. You just prefix a repo URL:

git clone --depth=1 https://gitdelivr.net/github.com/torvalds/linux

and you get it served from Cloudflare edge servers closest to you, cached in Cloudflare's object storage (R2).

The idea came from reading that GNOME had to redirect git clone traffic to GitHub mirrors because their GitLab bandwidth bill [1]. As a long time open source contributor and FOSS mirror hoster myself, it seemed surprising that this is a thing in 2026. We have jsDelivr for npm, and CDNs for Docker images and ML, but GNOME out of all projects has to move to use GitHub as a mirror.

Technically Git makes this surprisingly natural to cache as the same clone request produces the same packfile, so in my Workers code I hash the request body and use that as the cache key from R2. Refs get a short TTL of 60s.

The nice thing is you don't have to trust the proxy (I know the first question might be how do we trust you?) because git itself verifies every object hash client-side. And the source code is available on GitHub [2]. It's very light and turned out to be a weekend side project to help not just GNOME but anyone either facing a) egress bills b) not willing to move to GitHub or GitLab SaaS due to costs. It's 2026 so nobody should pay for egress if we have nice things like Cloudflare Workers + R2 :)

There's also support for Git LFS. Total cost to run is about $5/month.

I tested it with a dozen of different Git remotes: GitHub and GitLab of course but also, Codeberg, Gitea, and a few self-hosted instances.

This is meant to be used on public repos only, so private repos don't work but you can take the source code and adjust it and deploy it yourself.

If nobody uses it, it was a still fun project to see how far I can push Cloudflare's offerings. (long-time customer, but haven't really played around with Workers)

[1]: https://www.phoronix.com/news/GNOME-GitHub-GitLab-Redirect [2] https://github.com/emirb/gitdelivr.net

Similar Projects

Developer Tools●●Solid

Vibe-coded – Rust CLI to discover LLM-assisted Git repositories

Handy CLI that actually pulls a repo and runs a battery of concrete heuristics — repo age, README keywords/emoji counts, commit velocity, presence of LLM-tool files, and simple commit-statistics — to guess whether code was prompt-expanded. The rule set is intentionally arbitrary and extensible, which makes this a useful starting point for audits or CI checks, but expect false positives and plan to tune or add rules for your context.

Niche GemShip It
xlii
104mo ago