How i could redirect my Wordpress web site from http to https (ssl)?

Wordpress is tricky when you need to work out the http --> https redirection. There are many plugins out there that could help you with this redirection. This is a simple way using .htaccess rewrite rules to handle it. Replace your default rules installed by Wordpress installation in your .htaccess file.

FROM:

# BEGIN WordPress
RewriteEngine On
RewriteBase /
RewriteRule ^index\.php$ - [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /index.php [L]
# END WordPress


TO:

# BEGIN WordPress
RewriteEngine On
RewriteCond %{SERVER_PORT} !^443$
RewriteRule (.*) https://%{HTTP_HOST}%{REQUEST_URI} [R=301,L]
RewriteBase /
RewriteRule ^index\.php$ - [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /index.php [L]
# END WordPress



  • 0 Users Found This Useful
Was this answer helpful?
Related Articles
Copyright © 2020 PlusPlusHosting.Net. All Rights Reserved.
2Checkout.com is an authorized reseller of goods and services provided by PlusPlusHosting.Net.