PHP 8.6 was scheduled for release on November 19, right as WordPress 7.2 entered release candidate stage. Most site owners will never read a PHP changelog, but this release shows a gap that affects every WordPress site. PHP keeps moving forward, and WordPress deliberately stays several versions behind.
The headline features
The most talked-about addition is partial function application. It lets you “pre-fill” some of a function’s arguments and get back a new function waiting for the rest. It pairs well with the pipe operator introduced in PHP 8.5, and together they make chained operations much cleaner to write.
There is also a built-in clamp() function, which keeps a value inside a minimum and maximum range. WordPress doesn’t need to wait for it, because core already includes its own version as of 7.1.
Two further changes matter for WordPress in particular:
Better URL handling. PHP 8.5 added a native URI extension and 8.6 extends it. WordPress has a huge amount of its own URL-parsing code, so a native approach could eventually simplify a lot of it.
A Duration type. WordPress is full of time values: cache lifetimes, cron intervals, timeouts, nonce expiry. A proper duration type would make those APIs far less ambiguous than passing around bare numbers of seconds.
Free speed-ups
Some improvements need no work from anyone. PHP 8.6 optimizes closures, including converting some into more efficient static ones and caching closures that carry no state. If your host runs PHP 8.6 and your code is compatible, you get these gains automatically.
What could break
New versions also remove and deprecate things. Deprecation notices don’t usually crash a site, but they are a warning that the code will break in a future major version. This release deprecates the Oniguruma-based multibyte regex functions, such as mb_ereg() and mb_split(). Several type-check aliases like is_integer(), is_long() and is_double() are deprecated too. Plugin scans show these appear in thousands of WordPress plugins, so plugin developers have real cleanup ahead.
The core team is ahead of the curve. PHP 8.6 tests have been required to pass in WordPress’s automated test suite since November 10, and the known compatibility issues in core have been resolved.
The real problem: WordPress is built for the past
WordPress currently supports PHP 7.4 as its minimum version. That protects older sites but means core can’t use anything PHP has added since: named arguments, enums, readonly properties, property hooks and more.
The minimum version only rises when a version’s share of WordPress sites falls below 5%. PHP 7.4 has dropped from about 20.5% of sites in April to about 17% at the end of October. That is progress, but slow. Users have also grown less responsive to the old “upgrade for speed and security” message.
One idea from the WordCamp US discussion is feature gating. Rather than only warning people, WordPress and plugin developers would offer a genuinely useful feature only on newer PHP versions. Instead of telling people they should upgrade, you show them what they gain, and the upgrade is one click away.
One idea from the WordCamp US discussion is feature gating. Rather than only warning people, WordPress and plugin developers would offer a genuinely useful feature only on newer PHP versions. Instead of telling people they should upgrade, you show them what they gain, and the upgrade is one click away.
What you should do now
- Check your PHP version in your hosting panel, or under Tools → Site Health in WordPress.
- Move off any PHP version that no longer receives security fixes. Old runtimes are a risk like any other unpatched software.
- Test on a staging site first before switching versions, especially if you rely on older or abandoned plugins.
- Turn on error logging in staging to catch deprecation notices early.
- Ask your host which versions they support. If they lag far behind, consider switching.