logo

How to redirect HTTP to HTTPS? Print

  • 2

How to redirect HTTP to HTTPS??

 

Please use any of this below coding in your .htaccess file for redirection:

 

RewriteEngine On 
RewriteCond %{SERVER_PORT} 80 
RewriteRule ^(.*)$ https://www.example.com/$1 [R,L]

 

NOTE: Be sure to replace www.example.com with your actual domain name.

 

RewriteEngine On 
RewriteCond %{HTTP_HOST} ^example\.com [NC]
RewriteCond %{SERVER_PORT} 80 
RewriteRule ^(.*)$ https://www.example.com/$1 [R,L]

 

NOTE: Be sure to replace www.example.com with your actual domain name.

 

 

If still you are Facing any issue Please Click Here to raise a ticket to our Support team


Was this answer helpful?
Back