diff --git a/.htaccess b/.htaccess index 39b531a..53dda32 100644 --- a/.htaccess +++ b/.htaccess @@ -6,13 +6,14 @@ RewriteEngine On + # Uncomment if HTTPS is enabled. FYI, HSTS header increases security of your website & SEO + # + # Header set Strict-Transport-Security "max-age=31536000; preload" env=HTTPS + # + # Remove www subdomain in the URL # RewriteCond %{HTTP_HOST} ^www\.(.+)$ [NC] - # RewriteRule ^(.*)$ http://%1/$1 [R=301,L] - - # Force the URL to be https (only if you have an SSL certificate) - # RewriteCond %{SERVER_PORT} 80 - # RewriteRule ^(.*)$ https://%{HTTP_HOST}%{REQUEST_URI} [R=301,L] + # RewriteRule ^(.*)$ https://%1/$1 [R=301,L] # Redirect trailing slashes if it isn't a folder RewriteCond %{REQUEST_FILENAME} !-d