I have a main domain where I serve my website, and then I have subdomains that I use to deploy other projects which may be temporary. Having set up a deployment system with docker and letsencrypt, each project automatically has their own certificates.

Now my questions is, if I add includeSubDomains and preload to the HSTS directive, can I still have a separate certificate for each subdomain?

I read that all the directive above does, is tell the browser that my domain and subdomains will always be served over HTTPS but it's the preload that scares me. I'm afraid it will cache the certificate from the main domain and use it in the subdomains.

1 Answer 1


Yes, you can use different certificates and change certificates as much as you want, as long as you keep using HTTPS. HSTS, preload included, does not restrict what certificates you can use. It only forces you to use HTTPS.

(HPKP, on the other hand, restricts what certificates you can use. But that is another story.)


You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .