How can I redirect http to https?

Create an .htaccess file with the following contents and upload it to your public_html directory.

   RewriteEngine On
   RewriteCond %{SERVER_PORT} !443
   RewriteRule (.*) https://www.yourdomain.com/ [R]

another method:

   RewriteEngine On
   RewriteCond %{HTTPS} !=on
   RewriteRule ^(.*)$ https://%{HTTP_HOST}%{REQUEST_URI} [L,R=301,NE]
   Header always set Content-Security-Policy "upgrade-insecure-requests;"

  • 503 Users Found This Useful

Was this answer helpful?

Related Articles

Howto: Add another website to your account

You can add another website to your hosting account if your hosting plan allows for more than one...

I updated my site but I still see old pages

Make sure your files are indeed updated by checking the file time stamps. Also, you may want to...

Do you support TeamSpeak?

We do not support Teamspeak on our servers but allow you to create a subdomain such as...

Disable error_log via htaccess

Prevent public display of PHP errors via htaccess# supress php errorsphp_flag...

Reseller: Unable to find an IP address in when creating an account

When creating accounts be sure to select a package in the package field. You can create a package...