🛑 How to Disable Mandatory SSL on a cPanel Server

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

  1. 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
  2. Modify the Following Settings Locate and change the following lines: requiressl=1 alwaysredirecttossl=1 Change them to: requiressl=0 alwaysredirecttossl=0
  3. 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 SSLalwaysredirecttossl
  • Require SSLrequiressl

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.

Scroll to Top