X-frame-options header not updated - Cached headers?

On our Gatsby website, we generate a valid _headers file using gatsby-plugin-netlify and everything is fine.
All headers rules are generated and processed.
But I am noticing that something might be cached on netlify side, since the X-Frame-Options that we have just introduced, is not being updated on our main domain, but when deploying (same repo, same code) on a new context/branch I can see the updated X-Frame-Options header

Here is my generated _header file, that is properly processed and validated

Created with gatsby-plugin-netlify

  X-Frame-Options: ALLOW-FROM https://example.com/
  X-XSS-Protection: 1; mode=block
  X-Content-Type-Options: nosniff
  Referrer-Policy: same-origin
  Cache-Control: public, max-age=0, must-revalidate

After deploy:

curl -I mydomain.com

x-frame-options: DENY
x-xss-protection: 1; mode=block
age: 0
server: Netlify
cache-control: public,max-age=0,must-revalidate

Does anyone know if headers are cached and - if so - how to purge it?


They shouldn’t be cached unless you (or gatsby on your behalf) has done something rather unexpected.

What is the actual URL that shows the behavior, so we can see what headers are deployed with your site for that path and best advise?