WHMCS tips and tricks: Serving WHMCS 100% over SSL

At one time, WHMCS and SSL played nice. All you had to do was add your ‘WHMCS system URL’ (in admin -> settings) to https://yourdomain.com. Unfortunately, somewhere along the line in v6, WHMCS and SSL stopped playing nice. Here’s a guide serving WHMCS 100% over SSL in v6, with no errors or redirect issues.

The problem:

Getting SSL working with WHMCS can be tricky. Even if you have your system URL set to https://yourdomain.com/ , WHMCS tries to be ‘intelligent’ about this (it’s not) and send only some traffic over SSL, with other over http:// . While this wasn’t an issue in earlier versions , in v6, people started reporting that this didn’t have the same behavior.

The solution:

Serving WHMCS 100% over SSL can be achieved. There’s a few steps to doing so, but it can be achieved. Others have seen redirect issues, but I’ve yet to see any sort of redirect issue if these steps are followed precisely.

#1: Go to admin -> setup -> security, and untick ‘force admin ssl’ . It won’t be needed
#2: Go to admin-> setup -> general settings and remove the values for ‘System SSL URL’. Take note of them, you’ll need them
#3: Go to admin -> setup -> general settings and enter the values that were in step 2 in ‘System URL’.
#4: In your site’s .htaccess file, add the following code at the bottom

RewriteCond %{HTTPS} !=on
RewriteRule .* https://%{SERVER_NAME}%{REQUEST_URI} [R,L]

This will rewrite any http:// requests to https:// . As well, WHMCS will now load any form submissions, etc, over https, not http, which it should have been doing all along.

See? I told you serving WHMCS 100% over SSL can be achieved. Just a few short steps, no redirect errors, and you’re good to go!