redirect "http://" to "https://" on plane html website

Redirect from http to https (basic html site)

It is very simple to acheive that by opening your website .htaccess file and adding the below code to it, then save the file. then simple hard refresh your browser nad see the result.

<IfModule mod_rewrite.c>

RewriteEngine On 

RewriteCond %{SERVER_PORT} 80 

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

</IfModule>

 

  • Email, SSL
  • 0 Kunder som kunne bruge dette svar
Hjalp dette svar dig?

Related Articles

How to link a domain name into a hosting server using DNS nameservers

In order to link your domain (no matter where it is reserved with any registrar) to a new hosting...

Powered by WHMCompleteSolution