The Two-Tier Architecture: Browser Cache vs. CDN Edge (s-maxage)
Modern web delivery relies on two distinct caching layers: the visitor's local browser disk/memory cache and the global CDN edge network.
By combining max-age and s-maxage, you can achieve the best of both worlds. For example, setting Cache-Control: public, max-age=0, s-maxage=86400, stale-while-revalidate=604800 allows your CDN edge to absorb 99% of global traffic with instantaneous edge hits, while visitor browsers always revalidate with the CDN edge to guarantee prompt updates upon publishing new content.