Examples
An index of the standalone Cloudflare Workers and Cloudflare Pages example repositories that demonstrate zfb in real, deployable projects.
zfb ships a set of standalone example repositories, each one a small, deployable project that demonstrates a single Cloudflare recipe end to end. Every repo is independently pnpm install-able and includes its own README with local run steps and Cloudflare provisioning commands — clone one to see the whole thing assembled rather than copying snippets piecemeal.
Demo URLs go live after first deploy
Each Worker demo URL below resolves once that repo's Cloudflare secrets are configured and it has deployed at least once. Until then, some links may 404 — check the repo's README for its current deploy status.
Cloudflare Workers (Static Assets) — 7
These deploy as a Cloudflare Worker with Static Assets, the pattern covered in SSR and Cloudflare Bindings.
| Example | Demo | What it shows |
|---|---|---|
| ai-summarizer | Demo | Preact island UI + a Workers AI–backed / route, with a deterministic local fallback when the AI binding is absent. |
| json-api | Demo | SSR/API starter: / (filter + paginate) and / (lazy MiniSearch index), consumed by one island. |
| kv-guestbook | Demo | Workers KV guestbook: a prerender = false no-JS form + JSON API + admin delete, backed by a KV namespace. |
| password-gate | Demo | Static preview site behind a hand-written Worker password gate (run_worker_first = true). |
| reverse-proxy | Demo | Catch-all SSR reverse proxy (/ → PROXY_ORIGIN) with hop-by-hop / cookie / security-header hygiene. |
| workers-cache | Demo | SSR Workers Cache recipe: explicit cache headers + Cache-Tag + a token-protected purge route (ctx.cache.purge()). |
| webshop | Demo | SSR shop on Cloudflare (migrated Pages → Workers Static Assets) + D1 (per-preview databases, migrations in CI). |
Cloudflare Pages — 2
These deploy as a static site to Cloudflare Pages and are live today.
| Example | Demo | What it shows |
|---|---|---|
| blog | Demo | Tailwind blog with content collections, pagination, tags, and a hydrated theme-toggle island. |
| corporate-website | Demo | Static corporate site using CSS Modules. |