415.tech
AI & tech, from the frontlines of Silicon Valley
Cloudflare ships Workers Cache, a tiered cache in front of every Worker

Cloudflare ships Workers Cache, a tiered cache in front of every Worker

Cloudflare launched Workers Cache, turned on with one line of Wrangler config and the standard Cache-Control headers; on a cache hit the Worker never runs and CPU billing stays at zero. With frameworks like Next.js and Astro now making the Worker the origin, a developer can server-render on demand, cache the result, and serve later requests from cache — with full stale-while-revalidate so background refreshes never block a request. It is live today for every Worker on any plan, with per-entrypoint control over which routes cache.

Source: blog.cloudflare.com

Post on XEmail

On a cache hit, your Worker doesn't run at all. Cloudflare returns the cached response and your CPU billing stays at zero.

Cloudflare

Why this matters

  • → Server-rendered Workers now cache results, eliminating per-request CPU costs on cache hits.
  • → Developers gain static-site speed without build delays, using standard HTTP Cache-Control headers.
  • → Stale-while-revalidate keeps pages feeling instant even during background refreshes.
Cache in front of code