megachangelog
Breaking

Vercel CDN no longer caches responses with Vary: Cookie

Vercel CDN has changed its caching behavior to exclude responses with the Vary: Cookie header, as cookies often contain visitor-specific values that create cache entries with poor reuse rates. Users can identify affected responses via the x-vercel-cache header showing MISS and vary_key_denied:cookie in Runtime Logs, and can restore caching by removing Cookie from the Vary header or using Cache-Control: private if the response depends on cookies.

Vercel CDN no longer caches origin responses when includes . VaryCookie

tells a cache which request headers may change the response. Because cookies often contain visitor-specific values, varying by can create many cache entries that are rarely reused. The response is still served normally but isn't stored for future requests.VaryCookie

You can identify these responses by checking the header and . The header is set to , and Logs show as the cache reason.x-vercel-cacheMISSvary_key_denied:cookieRuntime Logs

If Logs show for a route you expect to be cached, check the header returned by your origin:vary_key_denied:cookieVary

Caching behavior for other supported headers is unchanged.Vary

Learn more about and the .high-cardinality headers cache reasonvary_key_denied

Read more

  • If the response is the same regardless of cookies, remove from . Vercel CDN can then cache it if it meets the other caching requirements.CookieVary

  • If the response depends on cookies, keep in and use to prevent personalized responses from being stored in the shared CDN cache.CookieVaryCache-Control: private

cdncachingperformancevary-header

Source: original entry ↗

More from Vercel

Follow Vercel to get its new changes in your feed and email digest.

Announcement

Muse Wonder now available on AI Gateway

Meta's Muse Wonder model is now accessible through Vercel's AI Gateway, supporting coding tasks, multi-step agent workflows, and computer use with a 1M-token context window. Users can access the model via a single API key without creating a separate Meta account and use it for text, image, PDF processing, tool calling, and structured outputs.

ai-gatewaymodelsagentscodingmeta
Feature

Agents can now buy domains with the Vercel CLI

Vercel CLI now enables agents to discover, check availability, and initiate domain purchases through structured commands, with purchase confirmation remaining under user control via interactive terminal or dashboard approval.

clidomainsagentsapi
Announcement

New Pro teams default to 30-day deployment retention

Pro teams now default to a 30-day deployment retention period to balance keeping recent history available while reducing storage costs. You can configure a longer retention period in team settings if needed.

deploymentsstoragepro-teamspricing
See all Vercel changes →