sincecutoff.com
← all changes

Wrangler configuration enables the Workers HTTP cache

Introduced 2026-05-07 · score 0.96

HOW TO USE IT

When enabling the Workers HTTP cache, set `cache.enabled` to `true` in Wrangler configuration. For preview deployments, set `previews.cache` to override the top-level cache setting; omit it to inherit that setting.

{"cache":{"enabled":true}}
[cache] enabled = true
[previews.cache] enabled = true

WHY THIS HELPS

Enable an HTTP cache in front of a Worker’s `fetch` handler for a deployment or preview.

REQUIREMENTS AND LIMITATIONS

  • Version: 4.89.0
  • cache.enabled (required): Boolean that turns caching on or off.
  • previews.cache: Preview cache setting; overrides top-level `cache`, or inherits it when absent.
  • Prerequisite: Wrangler 4.69.0 or above.
  • The cache is an HTTP cache in front of the Worker's `fetch` handler.
  • `previews.cache` overrides the top-level `cache` setting for preview deployments and falls back to the top-level value when absent.
  • Docs conflict: The current configuration docs, updated October 3, 2026, say caching applies to every `fetch()` invocation. The v4.89.0 release note describes it as a cache in front of the Worker’s `fetch` handler; current docs postdate that release.

FIRST-PARTY EVIDENCE

Check the installed version and the source before using it. Entry JSON

Report a problem with this card