NoVarySearch.com

No-Vary-Search Header Checker

Validate a No-Vary-Search header against the current IETF draft and Chrome, or paste a link to get a suggested header.

Input: No-Vary-Search header value. The "No-Vary-Search:" prefix is optional.

Clear Example

Input: Or start from a link: paste a URL from an email, ad or campaign and get a suggested header.

Example

Links from emails often contain personal tokens. Nothing is stored, but the link stays in this page's address, so don't share the result page.

Output: Result

Draft (IETF -10)valid
Chromeworks

Where it applies

Chrome HTTP cacheapplies
Chrome prefetch and prerenderapplies Repeat the header as expects_no_vary_search in your speculation rules.
Caches that follow the draftapplies
CDNs and proxiesdepends Many build their cache key from the full query string. Set their query-string cache key to match.
Firefox and SafariunconfirmedSee browser support

Effective behaviour

  • These parameters are ignored: "utm_source", "utm_medium", "utm_campaign", "utm_term", "utm_content". All other parameters must match.
  • Parameter order counts.
  • The query is parsed and decoded before comparing, so ?a=%61 matches ?a=a, + matches %20, and empty pairs (&&) are dropped.

Conventional form

No-Vary-Search: params=("utm_source" "utm_medium" "utm_campaign" "utm_term" "utm_content")

Works in both the draft and Chrome.

Test this header with URLs →

What is No-Vary-Search?

No-Vary-Search is an HTTP response header. It tells caches (the browser HTTP cache, prefetch and prerender) which query parameters don't change the response. For example, /page?utm_source=x can then reuse the cached /page. This site sends one too: see how it works here.

Heads-up: the draft and Chrome disagree. Chrome (and MDN) use params for "ignore all" and params, except=(…) for "ignore all except". The current draft makes both invalid and writes except=() and except=(…) instead, which Chrome ignores. key-order and params=(…) lists work in both. The checker shows both verdicts. Read more in the guide →

Examples

HeaderWhat it doesDraftChrome
key-order Parameter order doesn't matter valid works
params=("utm_source" "fbclid") Ignore these parameters valid works
key-order, params=("utm_source") Both combined valid works
except=("id") Ignore every parameter except id (draft form) valid ignored
params, except=("id") Ignore every parameter except id (Chrome form) invalid works
except=() Ignore all parameters (draft form) valid ignored
params Ignore all parameters (Chrome form) invalid works
params=("a", "b") Broken: list items are separated by spaces, not commas invalid ignored
params=(utm_source) Broken: parameter names must be quoted strings invalid ignored

Read the full guide → How caches match URLs, safe and unsafe parameters, recipes and troubleshooting.

More tools