Skip to content
All articles

PHP 8.2 loses security fixes on December 31: what to check on your WordPress site

PHP 8.2 gets its last security fix on 31 December 2026. What changes, which PHP version to move to, and how to upgrade a WordPress site without breaking it.

Erblin Derguti

4 min read

On 31 December 2026, PHP 8.2 gets its last security fix. From 1 January, any new vulnerability found in PHP 8.2 stays unpatched by the PHP project. If your WordPress site runs on PHP 8.2, nothing switches off that day: the site keeps working, but on software that no longer gets security fixes.

This guide explains what changes, which version to move to, and how to upgrade without breaking the site.

What changes on 31 December

Each PHP version gets two years of active support, then two years of security fixes only. PHP 8.2 was released in December 2022, its active support ended in December 2024, and its security support ends on 31 December 2026. These are the dates on the official PHP supported versions page:

  • PHP 8.2: security fixes until 31 December 2026
  • PHP 8.3: security fixes until 31 December 2027
  • PHP 8.4: active support until 31 December 2026, security fixes until 31 December 2028
  • PHP 8.5: security fixes until 31 December 2029
  • PHP 8.6: released on 19 November 2026, security fixes until 31 December 2030

What happens next depends on your hosting provider. Some move every site to a newer version on their own schedule, some charge for extended support, and some leave 8.2 running unpatched. Check which one applies to you before the deadline, not after.

Which version to move to

WordPress recommends PHP 8.3 or greater. The current WordPress release, 7.1, is compatible with PHP 8.3, 8.4 and 8.5.

For most business sites, PHP 8.3 or 8.4 is the sensible step. Both are well tested with WordPress and with popular plugins, and they get security fixes until the end of 2027 and 2028. The newest versions give the longest support window, but plugins and themes take time to catch up, so only move to them after testing.

Step 1: find out what you run

  1. Your PHP version. In WordPress, open Tools, then Site Health, then the Info tab, and expand Server. Your hosting control panel shows it too.
  2. Your WordPress version. Update WordPress itself first if it is behind. Older releases support fewer PHP versions.
  3. Your plugins and theme. Note each one's version and when it was last updated. A plugin or theme without an update in the last two years is the most likely thing to break.

Step 2: test on a copy, not on the live site

Most breakages after a PHP switch come from an old plugin, an old theme or custom code that uses features newer PHP versions removed or changed. The safe way to find them is a staging copy of the site.

  1. Take a full backup of the files and the database, and make sure you can restore it.
  2. Create a staging copy of the site. Many hosts offer this in one click.
  3. Switch the staging copy to the new PHP version.
  4. Turn on error logging on the staging copy only (see below).
  5. Click through the pages that matter: the home page, contact forms, checkout, login, and any booking or member area.
  6. Read the error log. Deprecation warnings can wait. Fatal errors cannot.

To log errors without showing them to visitors, add these lines to the staging copy's wp-config.php, above the line that says to stop editing:

define( 'WP_DEBUG', true );
define( 'WP_DEBUG_LOG', true );
define( 'WP_DEBUG_DISPLAY', false );

Errors are then written to wp-content/debug.log.

Step 3: fix what breaks

  • Update first. Most compatibility fixes are already released by the plugin or theme author.
  • Replace abandoned plugins with maintained alternatives.
  • Custom code needs a review by the developer who wrote it, or by someone who can read PHP.

Step 4: switch the live site

  1. Pick a quiet time and take a fresh backup.
  2. Switch the PHP version in your hosting panel.
  3. Test the same pages you tested on staging, and clear any page or server caches.
  4. Keep the previous version available for a day or two, so you can switch back if something was missed.

If you do nothing

Your site will not stop on 1 January. The risk grows over time instead: every PHP vulnerability found after 31 December stays open on your server. And if your host upgrades PHP for you on its own schedule, that is the worst moment to discover that a plugin breaks.

Prefer not to do this yourself?

Our Website Care plan covers updates, backups, uptime monitoring and security checks for business websites. If you would like us to look at your site, send us a brief.

Related articles

Tell us what you are building.

Written brief in 48 hours. If we are not a fit, we will say so and point you somewhere better.

Start a project →