cPanelMichael

Administrator
Staff member
Apr 11, 2011
47,880
2,268
463
For some reason when I visit any of my domains it defaults to none-https.
Hello,

This is normal unless you enter "https" in the address bar of your web browser. You could setup a redirect for each website using the instructions on threads like this one:

SOLVED - Auto Force TLS

Thank you.
 

tdot

Active Member
Nov 2, 2017
29
1
3
UK
cPanel Access Level
Root Administrator
Used the following steps. It still doesn't seem to work. Is there something I am doing wrong?

Logged in as root
Created userdata directory under /etc/apache2/conf.d/
Uploaded includename.conf to /etc/apache2/conf.d/userdata/
Code:
RewriteEngine On
RewriteCond %{HTTPS} off
RewriteRule (.*) https://%{HTTP_HOST}%{REQUEST_URI} [R,L]
/usr/local/cpanel/scripts/rebuildhttpdconf
/usr/local/cpanel/scripts/restartsrv_httpd
 

cPanelMichael

Administrator
Staff member
Apr 11, 2011
47,880
2,268
463
Hello,

Try running the following command as well:

Code:
/usr/local/cpanel/scripts/ensure_vhost_includes --all-users
Thank you.
 

tdot

Active Member
Nov 2, 2017
29
1
3
UK
cPanel Access Level
Root Administrator
Hi, I have run that command. The domains are still not defaulting to https. Is there something else that could be misconfigured?

In the config file, I've tried -
RewriteCond %{HTTPS} yes
and RewriteCond %{HTTPS} no
 

cPanelMichael

Administrator
Staff member
Apr 11, 2011
47,880
2,268
463
Hello,

Have you tried clearing your browser cache or uploading a test HTML page and accessing it directly to rule out any issues with your browser cache or script configuration?

Thank you.