How To Redirect Http To Https Using .Htaccess - Webcom Kenya

Contact Info

Garden Estate Road, Cedar Court, Block A Room A3 & A7

+254 720 727 460

info@webcomkenya.com

Howdy! How can we help you?
Categories
< All Topics
Print

How To Redirect Http To Https Using .Htaccess

How To Redirect Http To Https Using  .Htaccess

1. Login to the cPanel, use the URL that was provided i.e. yourdomainname.co.ke/cPanel, then enter the cPanel login details to access the cPanel.

2. On the cPanel search for ‘File Manager’.

How to Upload Your Website Files

3. On the new window, Look for the public_html directory. The public_html directory is your web root, the directory in which you want to store all your website files. Click on ‘public_html’.

How to Upload Your Website Files

4. On the new tab look for .htaccess file if you can’t find the file you can search on the hidden files. Right click on ‘.htaccess file’ and click edit.

How To Redirect Http To Https Using .Htaccess

5. On the new window paste the following code and save, replace www.yourdomain.com with your domain name.

RewriteEngine On

RewriteCond %{SERVER_PORT} 80

RewriteRule ^(.*)$ https://www.yourdomain.com/$1 [R,L]

How To Redirect Http To Https Using .Htaccess

To purchase email hosting click here

For more updates and insights, follow us on Facebook @webcomcloud.

Table of Contents