HTTP Caching at the Edge
HTTP Caching at the Edge
Full-page and block-level HTTP caching with ESI support, Magento-aware cache rules, and config reloads that keep the cache warm.
Full-Page and Block-Level HTTP Cache
Varnish sits between OpenResty and the PHP backend as an HTTP reverse proxy cache. When a cacheable page is requested, Varnish serves it directly from memory without touching PHP or the database. For Magento storefronts, this means category pages, product pages, and CMS blocks are served in single-digit milliseconds after the first request warms the cache.
ESI for Partial Page Caching
Edge Side Includes (ESI) allow Varnish to cache a page in fragments. A product page can have its main content cached for hours while the cart block and user-specific sections are fetched fresh on each request. Magento's built-in ESI support tags these blocks automatically — Varnish assembles the final response from cached and uncached fragments in a single pass.
Config Changes Without a Cold Cache
When the cache rules change, the new VCL is compiled, checked, and switched in on the running Varnish, with no restart. The cache stays warm through the change, so shoppers never get a slow wave of uncached pages after an update. A VCL that fails to compile is rejected before it goes live.
Magento-Aware Cache Rules
The VCL is generated from the store's own Magento installation and then tuned by the platform: static assets are cached without cookies, every PHP container is allowed to purge, and cache headers that reveal internal details are stripped from responses. Stores that need their own rules can supply a custom VCL, which the platform keeps in place. Memory for the cache is sized per environment to fit the catalog and traffic. Read the Varnish docs for VCL, ESI, and cache invalidation details.
- HTTP reverse proxy cache for full-page and block-level caching
- ESI support for partial page caching of dynamic blocks
- In-place VCL reloads that keep the cache warm
- VCL generated from your own Magento installation
- Purge access for every PHP container
- Internal cache headers stripped from responses
- Custom VCL supported and preserved
- Cache memory sized per environment

