WHMCS holds customer data, payment tokens and the keys to your servers, which makes it a target. Most compromises exploit simple things: a default admin path, writable configuration, outdated versions or weak staff passwords. Work through this checklist after installation and review it every few months.
Before you start
- Administrator access to WHMCS and File Manager or SSH access to its files.
- A full backup of the WHMCS files and database.
Protect files and folders
- Lock configuration.php: set permissions to
400(or440) so it cannot be modified by PHP. - Move writable folders out of the web root: create
/home/user/whmcs_data/and moveattachments,downloadsandtemplates_cthere. Update paths under Configuration → System Settings → Storage Settings and set$templates_compiledirinconfiguration.php. - Move the crons folder: move
cronsoutside the web root, editcrons/config.phpto point to the WHMCS path, and update the cron job command. - Delete the install folder right after installation.
- Rename the admin folder: rename
adminto something unique and set$customadminpath = 'yourname';inconfiguration.php.
Secure staff logins
- Enable two-factor authentication under Configuration → System Settings → Two-Factor Authentication and force it for all administrators. See admin roles and 2FA.
- Give every staff member their own account with the least-privileged Administrator Role.
- Remove accounts of former staff immediately.
- Restrict admin area access by IP: add an
.htaccessrule in the admin folder allowing only your office or VPN IPs, or use General Settings → Security → Admin IP Whitelist where available.
Protect clients and forms
- Enable CAPTCHA (reCAPTCHA v3 or hCaptcha) on login, registration, checkout, contact and domain checker forms under General Settings → Security.
- Set Required Password Strength to at least 50.
- Offer two-factor authentication for clients too.
- Enable Fraud Protection (MaxMind or FraudLabs Pro) under Configuration → System Settings → Fraud Protection to review risky orders.
Secure the API
- Under General Settings → Security → API IP Access Restriction, allow only the IPs of systems that use the API.
- Create API credentials per integration under Configuration → System Settings → Manage API Credentials with a limited API role.
Server and transport
- Serve WHMCS only over HTTPS and enable HSTS.
- Use a supported PHP version with security updates.
- Put WHMCS on its own subdomain and, ideally, its own hosting account, separate from your WordPress site.
- Enable server-side malware scanning and a WAF (Imunify360 or ModSecurity).
Keep WHMCS updated
Apply security releases as soon as they are published. WHMCS announces them in the admin area and by email. See update WHMCS safely. Also update third-party modules and themes – outdated addons are a frequent entry point.
Monitor
- Review Utilities → Logs → Admin Log for logins from unknown IPs.
- Check Utilities → System → System Health regularly; it flags insecure settings.
- Keep daily off-site database backups.
