To force all web traffic to use HTTPS insert the following lines of code in the .htaccess file in your website's root folder.


# START FORCE HTTPS

RewriteEngine On
RewriteCond %{HTTPS} !=on
RewriteRule ^/?(.*) https://%{SERVER_NAME}/$1 [R,L]

# END FORCE HTTPS