My site needs a newer PHP version. How do I upgrade safely?

Also searched as: PHP version upgrade · PHP version update · PHP version update WordPress · PHP version upgrade tool

Updated 3 October 2026

Short answer

Each PHP version gets two years of full support and two more years of security fixes only, then nothing. At the time of writing (October 2026), PHP 8.2 is the oldest version still supported, and only until 31 December 2026. Upgrade on a copy of the site first: check that your code, framework and plugins support the new version, step up one version at a time, fix what breaks, then switch the live site's PHP version in your hosting panel.

What's the problem

Your host is warning that your PHP version is being retired, a plugin or package needs a newer PHP, or a security scan flags the version. You're worried that changing it will take the site down, because the last time someone tried, it did.

Why it happens

  • PHP versions have a fixed lifespan. Four years after release, a version gets no more fixes at all, including security fixes. Hosts then stop offering it.
  • New PHP versions remove old behaviour. Functions get removed and rules get stricter between major versions, so old code throws errors or warnings it never used to.
  • Plugins and packages lag. Old WordPress plugins, themes and Composer packages may not support new PHP, especially abandoned ones.

How to fix it

  1. Check where you are: your current PHP version (in your hosting panel) and the versions your framework, CMS, plugins and packages support.
  2. Make a full copy of the site and database on a staging site, or locally.
  3. Update plugins, themes and packages on the copy to versions that support the target PHP, and replace abandoned ones.
  4. Switch the copy to the next PHP version up, not straight to the newest. Check the PHP migration guide for that version.
  5. Test everything: pages, forms, logins, checkout, admin, and watch the error log for warnings.
  6. Repeat one version at a time until you reach a supported version.
  7. Switch the live site in your hosting panel, test it again, and keep the old version available briefly in case you need to switch back.

When to call Preventionlabs

If your plugins all support the new version and testing is clean, switch and you're done. Call us when the site depends on abandoned plugins or old custom code that breaks on every newer PHP, or it's custom PHP nobody left understands. A resurrection delivers the site running on maintained dependencies, protected to MVP level, deployed in your own hosting account.

Submit your project for a free assessment

Free assessment. $10,000 AUD flat to get it live, only if we take it on and you go ahead.

Sources

  1. PHP: Supported Versionsofficial docsEach release branch of PHP is fully supported for two years from its initial stable release.
  2. PHP: Supported Versionsofficial docsOnce the four years of support are completed, the branch reaches its end of life and is no longer supported.
  3. WordPress: Requirementsofficial docsPHP version 8.3 or greater.
← All of It used to work