Security alerts eMudhra CA compromise · Chrome drops the root Oct 27 Check your certificate → PHP2Shell · is your PHP version exposed? Check your site →

Help › Fix guides › HSTS not enabled

Fix guide · HTTPS · medium

HSTS not enabled

HSTS (HTTP Strict Transport Security) tells browsers to only ever use HTTPS for your site. Without it, a visit can start over plain HTTP, and someone on the same network (public Wi-Fi, a compromised router) can intercept that first request and keep the visitor on an unencrypted copy of your site.

Time to fix

5 minutes

Risk if ignored

Downgrade attacks on shared networks

Breaks anything?

Only if parts of the site are still HTTP-only

How to fix it

In the server block that listens on 443:

add_header Strict-Transport-Security "max-age=31536000; includeSubDomains" always;

Then: sudo nginx -t && sudo systemctl reload nginx

Unsure? Start with max-age=300 (five minutes), check nothing breaks, then raise it to a year.

Check your fix

Rescan and we’ll confirm it’s fixed.

Common mistakes

  • Sending the header on port 80 only. Browsers ignore HSTS received over HTTP.
  • Leaving out "always" on nginx, so error pages go out without it.
  • Turning on preload before every subdomain has HTTPS. Preload is hard to undo.

Still stuck?

Ask a human. We answer every ticket.

Tickets are answered 7am–7pm Pacific, usually within a few hours. Your whole conversation stays in your account.

Live chat, inside your ticket

On a Pro or Enterprise plan? Open any ticket and, when we’re online, chat with us live right there. The chat is saved on the ticket with everything else, so nothing gets lost.

Free plan: tickets only. Same people, same answers.

Not a customer yet? Questions about plans go to sales.