Commercial PHP scripts, such as WHMCS, some billing and licensing tools and premium modules, are often encoded with ionCube or SourceGuardian. They need a loader extension to run. On CloudLinux hosting you enable it yourself in a few clicks.
Before you start
- cPanel access with Select PHP Version.
- The PHP versions supported by your encoded software; check the vendor's requirements.
Typical error messages
- "The file … requires the ionCube PHP Loader ionCube_loader_lin_8.1.so to be installed"
- "PHP script … is protected by SourceGuardian and requires a SourceGuardian loader"
- A blank page or 500 error right after uploading an encoded script.
Enable the loader
- Go to cPanel → Software → Select PHP Version.
- Make sure a numbered version is selected (not native), one the vendor supports.
- In the extensions list, tick ioncube_loader or sourceguardian.
- The change saves automatically.
- Reload the script's page.
Note: ionCube releases loaders for new PHP versions some time after the PHP release, and encoded files must also be encoded for that PHP version. If your software only supports PHP 8.1, stay on 8.1 even if newer versions exist.
Check the loader is active
Create info.php with the line below, open it, search for "ionCube" or "SourceGuardian", then delete the file.
<?php phpinfo();Common combinations
| Software | Loader |
|---|---|
| WHMCS | ionCube |
| Many premium PHP scripts from marketplaces | ionCube or SourceGuardian |
| Some licensing modules for themes or plugins | ionCube |
Troubleshooting
Error still appears after enabling
- The domain is pinned to a MultiPHP version, so the selector is ignored (see PHP Selector vs MultiPHP).
- An old
php.inior.user.iniloads a differentzend_extensionpath; remove it.
"The encoded file has expired" or "incompatible version"
The files were encoded for a different PHP version, or the licence expired. Download the correct package from the vendor.
ioncube_loader is not in the list
No loader exists yet for that PHP version. Choose an older supported version (see changing PHP version).
All other extension and option settings are covered in PHP extensions and options.
Frequently asked questions
Can I enable both loaders?
Yes. ionCube and SourceGuardian can be enabled together if you run software encoded with each.
Is the loader a security risk?
No. It only decodes protected files at run time. Keep it disabled if you do not need it, to keep PHP lean.
Does the order of extensions matter?
The selector handles the load order for you; ionCube must load first, which CloudLinux configures automatically.
Do I need the loader for WHMCS?
Yes. WHMCS is encoded with ionCube, so enable ioncube_loader on a PHP version WHMCS supports.
Will enabling the loader slow my site?
The overhead is negligible for normal sites. Encoded files themselves run at near-normal speed.
Where do I report a missing loader?
Open a support ticket with the PHP version and software name; support can confirm whether a loader is available.
