Deprecated: Class Jetpack_Geo_Location is deprecated since version 14.3 with no alternative available. in /home/everyuseful/public_html/wp-includes/functions.php on line 6114
How to redirect everything to HTTPS - EveryUseful

How to redirect everything to HTTPS

Redirect all non-HTTPS traffic to HTTPS using htaccess

<IfModule mod_rewrite.c>
 RewriteEngine On
 RewriteCond %{HTTPS} !on [NC]
 RewriteRule ^(.*)$ https://%{HTTP_HOST}/$1 [R=301,L]
</IfModule>

for more htaccess tips, go to this url:

https://www.leaseweb.com/labs/tag/htaccess/

2 Replies to “How to redirect everything to HTTPS”

  1. I just wanted to write you this very small observation in order to thank about what you have discussed in this article.

  2. Thanks for another informative web site. Where else could I get that type of information written in such a perfect way? I’ve a project that I am just now working on, and I’ve been on the look out for such information.

Comments are closed.