HSTS not working

#2
The only difference I'm seeing in my settings is I leave Location blank and I add subdomains to the directive

Strict-Transport-Security: max-age=63072000; includeSubDomains
 
#3
The only difference I'm seeing in my settings is I leave Location blank and I add subdomains to the directive

Strict-Transport-Security: max-age=63072000; includeSubDomains
I managed to fix it, so I will leave the answer here if anyone else has the same problem.
I am using WordPress installation on Google Cloud Platform, so I had to add the header to wordpress Virtual Host instead of Example Virtual Host I was adding it to previously. On the screenshot below there is a command that worked for me. Just be sure to go to Virtual Hosts -> wordpress -> Context -> Add (+) and then add Context as shown in the screenshot below.
Screenshot from 2020-10-16 14-30-18.png
 
Top