Tools Security headers

Security headers checker

Check the six security headers your website should send, what each one does, and get ready-to-paste fixes for nginx, Apache, Cloudflare, Netlify and Vercel.

What are security headers?

Short instructions your website sends with every page, telling the visitor's browser to be careful: always use https, don't let other sites frame this page, don't guess file types. They cost nothing and close common gaps.

The six we check

Strict-Transport-SecurityAlways use https here, even if someone types http://.
Content-Security-PolicyWhere scripts, styles and frames may come from.
X-Content-Type-OptionsDon't guess a file's type.
X-Frame-OptionsDon't show this site inside another site's frame.
Referrer-PolicyDon't share the full page address with other sites.
Permissions-PolicySwitch off features like the camera that the site doesn't use.

Common mistakes

  • Adding headers to the http page only: browsers read them on the https page.
  • Setting them in two places (your host and Cloudflare) with different values.
  • Copying a strict Content-Security-Policy from another site: it can break your own pages. Start with the safe one we suggest and grow it.

Questions people ask

Will adding these break my site?
The suggestions here are chosen to be safe for nearly every site. The one to take slowly is Content-Security-Policy: our suggestion only stops framing, and anything stricter needs testing on your own pages.
Do I need X-XSS-Protection?
No. Browsers have dropped the feature it controlled, and the advice today is to leave it out.
Which page do you check?
Your home page over https, after any redirects, because that's the page visitors see first.