Updating WHMCS
You can check for the most recent updates and update WHMCS quickly and easily from directly within the Admin Area.
You can access this feature at Utilities > Update WHMCS.
Checking for Updates
The system automatically checks for updates periodically. When an update becomes available, a notification will appear in the Admin Area.
You can also check for updates manually by clicking Check for Updates. You may need to do this to see recent releases prior to the next automated check.
Updating WHMCS
If you see a An update is available message, you can click Update Now to begin an automatic update.
Make certain that you have performed all of our recommended steps to prepare before initiating an upgrade.
- This includes checking our release notes and system requirements, verifying the status of your customizations, testing the update on a testing environment, and performing a backup.
- For steps and more information and recommendations, see Prepare to Update WHMCS.
Requirements for Automatic Updates
WHMCS has several system requirements for automatic updates:
- A PHP memory limit of at least 128 MB.
- At least 250 MB of free disk space.
- The PHP
allow_url_fopen
setting is enabled. - The PHP
max_execution_time
setting is60
seconds or more. - The PHP Zip Extension or the
proc_open
PHP function are enabled. - The PHP
open_basedir
setting includes the entire WHMCS document root.
Verifying the Upgrade
After the update finishes, check to ensure that WHMCS is working properly. We recommend testing all of the important features and functions in WHMCS, like logging in as a client and as an admin, viewing products, submitting support tickets, and placing new orders.
We also recommend monitoring the alert messages at Configuration () > System Health for the 24 hours following the update:
Update Settings
You can also configure settings for your update channels, set a maintenance message to display during updates, and specify the directory to use for staging update files.
Update Channel
You can choose the update channel for your WHMCS installation. This setting indicates the least-stable version that you want to use for updates.
WHMCS ships new updates using the following update channel options:
Update Channel | Description |
---|---|
Stable | Only receive Stable updates (General Availability releases) to your installation. We recommend this update channel for most installations. |
Current Version | Only receive maintenance updates for the currently-installed major and minor version.
|
Release Candidate | Receive releases after beta testing but before we release them to the Stable tier. |
Beta | Receive the latest versions of WHMCS as we release them to the Beta tier. We only recommend selecting this update channel for development and testing installations. |
Patch and Maintenance Release Updates
If you are on a WHMCS version that is in Long-Term Support and we issue a patch for that version, you can perform an update to apply the patch without moving to a newer WHMCS version.
To do this:
- Select the Current Version update channel.
- Click Check for Updates to refresh the available version.
- Proceed with your update as usual.
You may wish to change this setting back to Stable after updating to ensure that future checks display the most recent stable version.
Temporary Update Path
The temporary path allows you to stage files during an update. For security reasons, ensure that this directory is outside of the public document root, like the attachments
, downloads
, and templates_c
directories.
- The path must be an absolute path (for example,
/var/www/html/update_temp
instead of~/update_temp
). - The PHP user must be able to write to this path.
Maintenance Message
Use this option to set a message to display to other admins and users whenever an update is in progress.
Update File Changes
During the update process, WHMCS will update all of the core files to ensure that WHMCS continues to work correctly. This includes updating the default templates and order forms.
Updates overwrite the following files:
- Language Files (
~/whmcs/lang
and~/whmcs/admin/lang
) - Default Templates (
~/whmcs/templates/six
and~/whmcs/templates/orderforms
) - WHMCS-Supplied Modules (
~/whmcs/modules/
) - Core WHMCS Files
When you initiate an update at Utilities > Update WHMCS, WHMCS will scan the default template directories. You will see a warning if the scan finds any customizations that updating would overwrite.
Customizations to Open-Source Files
We provide some WHMCS files as open-source code, in order to allow customization (for example, the /aff.php
file). Make certain that you back these customizations up before performing updates and restore them manually after the update is complete.
Preserving Customizations
When you customize parts of WHMCS, make certain to use the recommended methods:
- Copy the desired files if you want to customize a theme or template. Make certain that you do not store your customizations in the default template folders.
- Use override files if you want to customize a locale.
- Ensure that you create a uniquely-named copy of any modules that you customize.
- Ensure that you create override files for any changes to the shipped
dist.whois.json
anddist.additionalfields.php
files. To avoid overwriting your customizations, you must store changes in the appropriate override files.
Common Errors
You can find the log of Automatic Updater actions in the tblupdatelog
table in the WHMCS database. To troubleshoot upgrade problems, review this table for the most recent entries (the highest id
values). You can use a tool like phpMyAdmin to browse the table’s contents.
You may encounter the following common update-related errors:
Error | Description | Recommended Solution |
---|---|---|
WHMCS Not Installed Error | You may have overwritten the configuration.php file when you uploaded files during a manual upgrade. | Restore the configuration.php file from your most recent backup before continuing. |
Make certain that you have selected a valid Update Channel and then try again | You have not correctly configured the Update Channel setting. | Configure and save the update channel setting. For steps to update this setting, see Set the Update Channel. |
Unable to connect to the WHMCS Update Server | Your server could not connect to the WHMCS update server. You may see this error while using the Automatic Updater feature or in a log file. | To resolve this issue, run the following commands to check the connection:curl -v https://releases.whmcs.com/v2/packages.json curl -v https://pki.whmcs.com/ If the commands succeed, they will return a 200 status code. If you see a different code or another error, contact your hosting provider or system administrator. |
Permissions Errors | You may encounter one or more permissions errors if your system’s file and directory permissions do not allow WHMCS to perform the required actions during an update. For example:
| Make certain that all of your permissions settings allow WHMCS the correct access. For more information, see File Permissions. |
Bad Formatting | If you see incorrect formatting when you go to the Client Area or Admin Area, your browser may not have updated. | Clear your browser cache or perform a hard refresh (Ctrl + F5 ) and delete the contents of the template cache directory (templates_c by default). |
Down for Maintenance or Update in Progress | If, after uploading the files from a Patch Set, you see a Down for Maintenance or update in progress… message, the patch set files that you attempted to apply are not compatible with the version of WHMCS you were previously running. | Download the latest Full Release version and update using the regular update process above. |
Last modified: November 19, 2024