Answer the question
In order to leave comments, you need to log in
Always redirecting from HTTP to HTTPS?
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteCond %{HTTPS} !=on
RewriteRule ^(.*)$ https://%{HTTP_HOST}/$1 [R=301,L]
</IfModule>
Answer the question
In order to leave comments, you need to log in
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteCond %{HTTPS} =off
RewriteRule (.*) https://%{HTTP_HOST}/$1 [R=301,L]
</IfModule>
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question