Skip to content

HTTP Strict Transport Security

HSTS tells a browser to remember HTTPS for future visits to a host. Duration and subdomain coverage require a deliberate operational decision.

Also known asHSTS
IT security

Remember HTTPS for future calls

HTTP Strict Transport Security, or HSTS, is communicated through the response header Strict-Transport-Security. After receiving it over a secure HTTPS connection, the browser remembers to access this host only through HTTPS for the policy duration. Future HTTP addresses are rewritten accordingly. HSTS does not issue a certificate or repair TLS failures.

Check the scope before setting it

A fictional HTTPS response from portal.example contains Strict-Transport-Security: max-age=3600. This example value equals 1 hour and is not a general production target. The browser can store the rule for this host. Omitting the header later does not immediately cancel an already stored rule; its validity period continues.

Adding includeSubDomains would also cover descendant hosts. Before extending the scope, the team must check that every affected service is reliably available over HTTPS. A parent domain or a sibling host is not automatically covered.

If the browser has not learned the rule and no matching preload entry exists, the stored policy cannot protect the first HTTP request. Preloading is a separate process.

Sources