How to Change PHP Version in cPanel Without Breaking Your Site
A hosting provider sends out a notice that PHP 7.4 is being retired, you click over to MultiPHP Manager, bump the version to 8.1, and ten minutes later your site is throwing fatal errors it never threw before. This is one of the most common support tickets we see, and almost every time it's fixable in under fifteen minutes once you know where to look.
Why changing the PHP version breaks things
PHP versions aren't just faster or slower releases of the same language. Each major version removes old functions, changes default behavior, and tightens what used to be a warning into a fatal error. A plugin written in 2019 for PHP 7.2 might call a function that PHP 8.1 deleted outright. Your site doesn't get slower - it stops rendering.
The most common breakage sources, in order of how often we see them:
- An old or abandoned plugin using a removed or renamed PHP function
- A theme built years ago that never got updated for PHP 8.x's stricter type checking
- A custom script in
functions.phpwritten by a freelancer who's long gone - An outdated version of WordPress core itself (PHP 8+ needs WordPress 5.9 or newer to run cleanly)
Step 1: Check what you're running before you touch anything
Before switching, note your current PHP version and, if it's WordPress, your WordPress core version and plugin list. Log into WordPress Admin → Dashboard → Site Health → Info and look under "Server" for the current PHP version. Screenshot the plugin list too - if something breaks, you'll want a quick way to see what changed.
If you're managing a client site or anything with real traffic, take a full backup first. In cPanel, that's Backup Wizard or JetBackup depending on your plan - a full backup takes a few minutes and turns a bad PHP switch into a two-click rollback instead of a panic.
Step 2: Switch the version in MultiPHP Manager
- Log into cPanel and open MultiPHP Manager under the Software section.
- Select the domain (or all domains, if you manage several under one account) from the list.
- Choose the target PHP version from the dropdown - for most current WordPress sites, PHP 8.1 or 8.2 is the sweet spot between speed and compatibility.
- Click Apply.
The change is instant - no restart, no propagation delay. Reload your site immediately after to see if anything visibly broke.
If you only want to test the waters, some cPanel setups let you set a different PHP version for a staging subdomain first. If you have that option, use it - it's the safest way to catch a plugin conflict before it hits the live site.
Step 3: Read the actual error, don't guess
If the site goes white or throws a 500 after the switch, resist the urge to just flip the version back without checking why. The error log tells you exactly what broke, and often it's a five-minute fix rather than a reason to stay on an outdated, unsupported PHP version forever.
Check the error log in cPanel under Metrics → Errors, or via File Manager at public_html/error_log. You're looking for lines like:
PHP Fatal error: Uncaught Error: Call to undefined function create_function() in /home/user/public_html/wp-content/plugins/old-plugin/plugin.php on line 42
That tells you exactly which plugin and which line. create_function(), for example, was removed entirely in PHP 8.0 - it's one of the most common culprits in old plugins.
Common errors and what they mean
| Error message | Likely cause | Fix |
|---|---|---|
| Call to undefined function create_function() | Plugin uses a function removed in PHP 8.0 | Update the plugin, or replace with an actively maintained alternative |
| Uncaught TypeError: argument must be of type array, null given | PHP 8.x's stricter null handling | Update plugin/theme to a version with PHP 8 support |
| Uncaught Error: Class not found | Autoloader or namespace conflict, often from an old theme | Update theme, or check for a missing include |
| White screen, no visible error | Error display is off, error only in log | Check error_log or enable WP_DEBUG_LOG temporarily |
Step 4: Fix the actual plugin or theme, don't leave it hidden
Once you've found the culprit, you've got three real options:
- Update it. Most actively maintained plugins already have a PHP 8-compatible release. This is the fix nine times out of ten.
- Replace it. If it's abandoned (no update in 2+ years), find a maintained alternative that does the same job.
- Patch it yourself. If it's a small custom script, the fix is often a one-line change - swap a removed function for its modern equivalent.
Don't just revert to the old PHP version and call it done. Older PHP versions stop receiving security patches on a schedule (PHP.net publishes an official end-of-life date for every version), and staying on one past that date is a real security exposure, not just a compatibility inconvenience.
Step 5: Confirm the site is actually healthy, not just loading
A page loading isn't proof everything works. After switching, walk through:
- The homepage and at least one inner page
- Login to wp-admin
- A form submission (contact form, checkout, comment box - whatever your site uses)
- The WooCommerce checkout flow, if you run a store - payment gateway plugins are especially sensitive to PHP version changes
Check Site Health in WordPress again too - it flags PHP-related warnings even when the site otherwise looks fine.
Prevention: don't wait for a forced migration
The tickets we see aren't usually from people who chose to upgrade PHP on their own schedule - they're from people responding to a host's forced deprecation notice under time pressure. Two habits fix that:
- Keep plugins and themes updated on a regular basis, not just when something breaks. Outdated plugins are the single biggest cause of PHP version incompatibility.
- Test PHP version bumps on a staging copy or off-peak hours, even if it takes an extra ten minutes, rather than switching live during business hours.
If you're on Getwebup hosting and want a hand picking the right PHP version or diagnosing an error after a switch, our support team can pull the error log and pinpoint the exact plugin for you - just open a ticket with your domain name.
Frequently asked questions
Which PHP version should I use for WordPress in 2026?
PHP 8.1 or 8.2 is the safest choice for most current WordPress sites - it's fast, actively supported, and compatible with any actively maintained plugin or theme. Avoid PHP 7.x versions; they've reached end-of-life and no longer receive security patches.
My site broke after changing PHP version - how do I revert it fast?
Go back into MultiPHP Manager in cPanel, select the domain, and choose the previous PHP version from the dropdown, then click Apply. The change is instant, so your site will be back to its prior state within seconds while you fix the underlying plugin issue.
How do I know which plugin is causing the error after a PHP switch?
Check the error log in cPanel under Metrics > Errors or in public_html/error_log via File Manager. The fatal error line names the exact plugin folder and file where it failed, so you don't have to deactivate plugins one by one to find it.
Does switching PHP version affect email or databases?
No. MultiPHP Manager only changes how PHP scripts execute for that domain - it doesn't touch your MySQL databases, email accounts, or DNS settings. Only PHP-dependent parts of your site (WordPress, custom scripts, plugins) are affected.
Can I test a new PHP version without affecting my live site?
Yes, if your hosting plan supports it. Apply the new PHP version to a staging subdomain or a cloned copy of the site first, walk through the key pages and forms, and only switch the live domain once you've confirmed nothing breaks.