Choose how long browsers remember your HSTS policy

  • max-age

    The number of seconds a browser should remember the HTTPS-only policy.

  • includeSubDomains

    Extends the policy to subdomains, including names that may serve different applications.

The header reference describes these directives. Confirm that affected hosts work over HTTPS before extending the policy.

Always-use-HTTPS setting (HSTS) is missing or weak

Check every subdomain before requesting HSTS preload

  • Preloading adds a domain to a list that ships with browsers, so they can require HTTPS even on a first visit, without learning the policy from an earlier one. Check every subdomain, including internal services, before asking to join the list.

  • Adding preload to a header doesn't submit your site. The preload site recommends HSTS but not preloading, because many browsers already upgrade navigations to HTTPS. It also lists the requirements if you still want to submit.

Plan for the delay in HSTS preload removal

  • Removing the header doesn't erase a policy browsers have already stored. Sending max-age=0 clears that stored policy when a browser receives it over HTTPS, but it doesn't remove an entry from the browser's preload list.

  • Preload removal is a separate request. The removal page says a removal may take 6 to 12 weeks to reach most Chrome users, and longer in other browsers. Keep HTTPS working through that process.

Frequently asked questions

Does HSTS replace my HTTP to HTTPS redirect?

No. Without a remembered or preloaded policy, a browser can still make an initial HTTP request. Keep the server redirect as well.

What happens with HSTS if my SSL certificate expires?

Browsers that remember your HSTS policy won't let visitors click past the certificate error, so make sure certificate renewal keeps working.

  • Domain health

    Fix the setup mistakes that make browsers warn people away from your site.

  • Security headers

    Learn which response headers guide browser behavior and where to add them.

  • HTTP to HTTPS redirect

    Send HTTP requests to their HTTPS destination and avoid conflicting redirect rules.

  • Mixed content

    Replace insecure file and form addresses that remain on an HTTPS page.

  • Security headers that are not your CSP

    What HSTS, Referrer-Policy, Permissions-Policy, and the cross-origin isolation headers actually prevent, how to verify each one, and which are noise.