If you’re looking to disable the requirement for SSL on cPanel/WHM, you can do this manually by editing the configuration file or using WHM API commands.
Method 1: Manually Edit cPanel Configuration File
- Edit the cPanel Config File Open the file
/var/cpanel/cpanel.config
with your preferred shell text editor (e.g.,nano
,vi
, etc.):nano /var/cpanel/cpanel.config
- Modify the Following Settings Locate and change the following lines:
requiressl=1 alwaysredirecttossl=1
Change them to:requiressl=0 alwaysredirecttossl=0
- Apply the Changes Run the following command to apply the changes:
/usr/local/cpanel/whostmgr/bin/whostmgr2 --updatetweaksettings
Method 2: Using WHM API Commands
If you prefer using the API instead of manually editing files, run the following commands:
whmapi1 set_tweaksetting key=requiressl value=0
whmapi1 set_tweaksetting key=alwaysredirecttossl value=0
These commands instantly update the configuration without needing to manually apply settings.
Related WHM Settings
These two options in the /var/cpanel/cpanel.config
file correspond to the following settings in WHM:
- Always redirect to SSL →
alwaysredirecttossl
- Require SSL →
requiressl
You can find and adjust them in WHM at:
WHM >> Server Configuration >> Tweak Settings
⚠️ Important: Disabling SSL is generally discouraged for production environments due to security risks. Use this setting only for internal testing or isolated legacy systems.