PHP 8.2 Goes End of Life on 31 December. Here's What That Means for You
By Zachary, Hawthorn Security
In a few weeks, on 31 December 2026, PHP 8.2 reaches end of life. After that date the PHP project stops releasing security fixes for it. No patches, no backports, nothing.
If last month's PHP2Shell scramble taught us anything, it's that the gap between “a bug is found” and “attackers are using it” is now measured in hours. Running a PHP version that will never be patched again is a much bigger risk than it used to be.
Here's what's changing, who it affects, and what to do about it.
How PHP support works
Every PHP version now gets four years of support:
- Two years of active support, with bug fixes and security fixes.
- Two years of security-only support, where only security issues get patched.
- Then it's end of life.
All of these phases now end on 31 December of the relevant year, which makes planning a bit easier.
PHP 8.2 came out in December 2022. Its active support finished at the end of 2024, and it's been on security fixes only ever since. That ends on New Year's Eve.
Here's where the current versions stand:
| Version | Security support until | Status |
|---|---|---|
| PHP 8.1 and older | Already ended | Unsupported |
| PHP 8.2 | 31 December 2026 | Final weeks |
| PHP 8.3 | 31 December 2027 | Security fixes only |
| PHP 8.4 | 31 December 2028 | Fully supported |
| PHP 8.5 | 31 December 2029 | Fully supported |
Why this matters more than usual
PHP2Shell is a perfect example. When those two critical bugs were fixed in October, the supported branches (8.2 to 8.5) got proper releases on the day. The end-of-life branches (7.4, 8.0 and 8.1) only got source code backports, with no official release. If you were on one of those, you were relying on your Linux vendor, a third-party repository, or compiling PHP yourself.
Now imagine a bug like that turns up in February. PHP 8.2 would be in exactly the same position.
And there are a lot of sites on 8.2. According to WordPress.org's own stats from September, around 62% of WordPress sites were running PHP 8.2 or older. That's a huge number of sites that are either already unsupported or about to be.
“But my server's still getting updates”
This is where it gets a bit nuanced, and where a lot of people get caught out.
Some Linux distributions keep patching their own PHP packages after the official end of life:
- Debian 12 ships PHP 8.2 as its default, and Debian's security and LTS teams continue to patch the packages they ship for as long as that release is supported.
- Red Hat Enterprise Linux 8 and 9 support their PHP 8.2 streams until May 2029.
So if you're on Debian 12 with Debian's own PHP packages, and your server is actually installing security updates, you're not instantly exposed on 1 January.
But that comes with some big caveats:
- It only covers the distro's own packages. If you installed PHP from a third-party repository, a control panel, or a Docker image, the distro's support doesn't apply to you.
- Your software moves on without you. Frameworks, CMSs and plugins will drop 8.2 support. Laravel 13 already requires PHP 8.3, as do Drupal 11 and Joomla 6. Over time you'll be stuck on older versions of everything else too, and those stop getting security fixes as well.
- It's only as good as your update process. A distro patch you never install protects nothing.
- There's no upgrade path within Debian 12. It doesn't ship PHP 8.3, so moving forward means either upgrading to Debian 13 (which uses PHP 8.4) or switching to a third-party repository.
Distro support buys you time. It isn't a plan.
Which version should you move to?
For most people, I'd recommend going straight to PHP 8.4. It's supported until the end of 2028, it's the default on Debian 13, and most major frameworks and CMSs work well on it.
- PHP 8.3 is the smallest jump if your code or plugins aren't ready for 8.4, but it only buys you one more year.
- PHP 8.5 gives you the longest runway if everything you use already supports it.
Whichever you pick, test it first. Most upgrades from 8.2 are fairly painless, but deprecated features, older plugins and abandoned packages are where things usually break.
What you should do now
- Find out what you're running. Check every server, site and container, including the command line PHP used by cron jobs and queue workers, which is often a different version from the web server.
- Check your dependencies. Make sure your framework, CMS, plugins and Composer packages support your target version.
- Test on a copy first. A staging site or a local copy will save you a lot of stress.
- Plan the operating system too. If you're on an older OS, the PHP upgrade might mean upgrading the server as well.
- Don't leave it until December. The last two weeks of the year are when nobody's around to fix things if the upgrade goes wrong.
Want a hand?
This is exactly the kind of thing a Hawthorn Security review is for. I've spent over 15 years building and running PHP and Laravel applications and the Linux servers behind them, so I've done more of these upgrades than I can count.
A review looks at what you're running, where the end-of-life risks are (PHP, the operating system, and your framework and packages), and gives you a clear, prioritised plan to get onto supported versions without breaking anything.
If you're not sure what version your site is on, or who's meant to be keeping it updated, now's a good time to find out.
Book a security review at hawthornsecurity.uk