Skip to content

PHP 8.6 for WordPress on cPanel: when to upgrade

Decide when to move a WordPress or WooCommerce site on cPanel to PHP 8.6, which was released on 19 November 2026. You will check what your server and WordPress support today, test your plugins and theme against 8.6 on a copy, and know the conditions for switching.

If you run a WordPress or WooCommerce site on a cPanel server, you now have to decide when to move it to PHP 8.6.0, released on 19 November 2026. You need to know whether the switch is safe yet, what could break, and how to test first. As of 20 November 2026, keep production on the PHP branch it runs today and install this week’s security update for that branch. cPanel has not shipped a PHP 8.6 package yet, and WordPress has not listed 8.6 as supported. Use the wait to test your plugins and theme against 8.6 on a copy, then move once the three conditions in step 7 are met.

What you’ll accomplish

  • Know where each layer stands on 20 November 2026, with a link to check it again later.
  • Confirm from the command line whether your own server offers PHP 8.6.
  • Run your plugins and theme through PHP 8.6 in a container, without changing the server.
  • Get a list, per plugin, of the code that PHP 8.6 deprecates or treats differently.
  • Decide between wait, test now and move, using written conditions.

Prerequisites

  • A cPanel account with SSH access, and WP-CLI (the wp command). The package checks in step 2 need root on the server, or a question to your host.
  • A computer or test server with Docker installed. Docker runs PHP 8.6 in a container, a separate process with its own files, so nothing on the cPanel server changes.
  • Disk space on that machine for a copy of wp-content without its uploads. The test reads the copy and never writes to the live site.
  • The paths here assume the site lives in ~/public_html. The package names assume EasyApache 4, the cPanel system that installs PHP as ea-php84, ea-php85 and so on. CloudLinux servers that use PHP Selector have alt-php84, alt-php85 and so on under /opt/alt/.

How it works

Four layers each have to say yes before production moves. PHP itself has to be released. Your server vendor has to package it. WordPress core has to support it. Then your own plugins and theme have to pass. Only the first layer is done today.

A ladder of five steps toward running PHP 8.6 in production, with the status of each on 20 November 2026. Step one, PHP 8.6.0, is ready: it was released on 19 November 2026. Step two, the server package ea-php86, is waiting: it is not in EasyApache 4 yet. Step three, WordPress core, is waiting: its support table has no PHP 8.6 column. Step four, your plugins and theme, is highlighted as the one to start now by linting and searching a copy under 8.6. Step five, production, comes last, only after the four above say yes.

Where each layer stands, as of 20 November 2026

LayerStatus as of 20 November 2026Where to check
PHP 8.6.0Released 19 November 2026. Active support runs to 31 December 2028 and security fixes to 31 December 2030.Release page, supported versions
cPanel EasyApache 4No ea-php86 package. Release 25.98 of 19 November 2026 updated ea-php82 to ea-php85 only. Release 25.97 of 18 November has one PHP 8.6 entry, an update to the settings data that cPanel keeps for each PHP version.EasyApache 4 change log
CloudLinux alt-php86Not checked for this page, as of 20 November 2026. Check your own server with step 2.Step 2
WordPress coreThe compatibility table, last updated on 4 November 2026, stops at PHP 8.5 and has no 8.6 column. The newest release is WordPress 7.1.5 of 18 November 2026.PHP compatibility table
PHPCompatibility, a rule set for the PHP_CodeSniffer code scannerVersion 10.0.0-alpha3 of 17 November 2026 adds checks for PHP 8.6. It is an alpha release, so treat its results as a second opinion.Release notes
Docker imagephp:8.6-cli was published on 19 November 2026.Docker Hub

Nothing forces the move this year. PHP 8.3 gets security fixes until 31 December 2027, PHP 8.4 until 31 December 2028 and PHP 8.5 until 31 December 2029. The urgent job this week is on your current branch. On 19 November 2026, php.net also published the security releases 8.5.13, 8.4.28, 8.3.37 and 8.2.36. Its advance notice of 18 November rated the highest severity as critical. It added that the critical issues need a non-default configuration or an uncommon setup. The PHP ChangeLog lists CVE-2026-115560, a flaw in session handling, among the fixes. cPanel shipped all four in release 25.98, so update the branch you are on before you think about 8.6.

What PHP 8.6 changes for WordPress-style code

The official lists are the backward incompatible changes, the deprecated features and the other changes. These are the entries most likely to meet plugin and theme code.

Change in 8.6EffectHow to find it
return inside a finally block, a value returned from __construct() or __destruct(), a function named readonlyDeprecation notice when the file loadsStep 4 prints them
is_double(), is_long(), is_integer(), doubleval(), spl_object_hash(), spl_classes(), strcoll(), metaphone(), mysqli_get_charset(), mysqli_stmt_init(), the SORT_LOCALE_STRING flagDeprecation notice on each callStep 5
mb_split(), mb_ereg() and the other mbstring regex functionsDeprecation notice now. The PHP manual says they will be removed in PHP 9.0.Step 5
A third argument passed to define()Deprecation notice for false, warning for trueStep 6
Session defaults are now session.use_strict_mode=1, session.cookie_httponly=1 and session.cookie_samesite="Lax"No notice. A plugin that calls session_start() gets a stricter cookie, unless the server or the plugin sets these values itself.Step 6
ValueError for invalid flags to array_filter(), pathinfo() and scandir(), and for a NUL byte (a zero byte) in a path given to file_exists(), is_file() and similarAn uncaught exception stops the request with a fatal errorOnly by running the site
trim() also strips the form feed character, preg_grep() returns false on a regex engine error, and fclose(), file_put_contents() and copy() return false when flushing or closing the file failsSilent change in a return valueOnly by running the site

A deprecation is a notice, and the site keeps working. PHP logs a line that starts with Deprecated: and finishes the request as before. The plugin author has to change that code before a later PHP version removes the feature. WordPress hides these notices unless WP_DEBUG is set to true in wp-config.php.

When notices are logged on cPanel, they go to one of three places. With WP_DEBUG_LOG also set to true, WordPress writes them to wp-content/debug.log. Otherwise, a domain on PHP-FPM (FastCGI Process Manager, the pool of PHP worker processes that cPanel can enable per domain) logs by default to ~/logs/<domain_tld>.php.error.log. The file name is the domain with its dots replaced by underscores, such as example_com. Without PHP-FPM, PHP on cPanel usually writes a file named error_log in the folder of the script that ran. If you find neither, open MultiPHP INI Editor in cPanel and read the error_log value for the domain.

The session change needs more care, because it logs nothing. WordPress 7.1.5 core never calls session_start(), so core is not affected. Some plugins and themes do start a PHP session, and those are the code to test.

Step-by-step

1. Record what the site runs today. Run this from the site root on the cPanel server:

wp core version
wp cli info | grep -E 'PHP (binary|version)'
wp plugin list --status=active --fields=name,version,update

Example output:

7.1.5
PHP binary:	/opt/cpanel/ea-php84/root/usr/bin/php
PHP version:	8.4.28
+----------------------+---------+-----------+
| name                 | version | update    |
+----------------------+---------+-----------+
| example-forms        | 3.8.2   | none      |
| example-shipping     | 2.14.0  | available |
| woocommerce          | 11.3.0  | none      |
+----------------------+---------+-----------+

Keep this output. The PHP version must be at least 8.5.13, 8.4.28, 8.3.37 or 8.2.36, depending on your branch. An older number means the security update is still missing. WP-CLI reports the command-line PHP, which can differ from the one serving web pages. To read the web version, see how to check the PHP version.

2. Check whether your server offers PHP 8.6. Any shell user can list the installed versions:

ls -d /opt/cpanel/ea-php*

Example output:

/opt/cpanel/ea-php82  /opt/cpanel/ea-php83  /opt/cpanel/ea-php84  /opt/cpanel/ea-php85

As root, ask the package manager whether the vendor has published 8.6:

dnf list available 'ea-php86*'
dnf list available 'alt-php86*'

The second command is for CloudLinux. As of 20 November 2026, the expected reply to the first command is Error: No matching Packages to list. A list of package names means the vendor has shipped 8.6 since this page was written. On cPanel for Ubuntu, run apt list 'ea-php86*' instead. An empty list after the Listing... line means the same thing.

3. Copy the code to the machine that has Docker. Run this on that machine, with your own SSH user and host:

mkdir -p ~/php86-test
rsync -a --exclude 'uploads' --exclude 'cache' exampleuser@server.example.com:public_html/wp-content/ ~/php86-test/wp-content/
ls ~/php86-test/wp-content

The last command must list at least plugins and themes. The copy leaves out uploads and cache files, which hold no code to test.

4. Lint every file under PHP 8.6. Linting asks PHP to parse a file without running it. The :ro flag mounts the copy read-only.

cd ~/php86-test
docker run --rm -v "$PWD/wp-content:/src:ro" php:8.6-cli \
  find /src/plugins /src/themes -name '*.php' -exec php -l {} \; 2>&1 \
  | grep -Ev '^(No syntax errors|$)' | tee lint.txt

Example output:

Deprecated: Returning a value from a constructor is deprecated in /src/plugins/example-forms/includes/class-loader.php on line 4
Deprecated: Returning from a finally block is deprecated in /src/plugins/example-forms/includes/class-loader.php on line 11
Parse error: syntax error, unexpected token "{", expecting variable in /src/themes/example-child/functions.php on line 2
Errors parsing /src/themes/example-child/functions.php

No output at all is the best result. A Parse error line is a blocker, because that file cannot load on 8.6. A Deprecated: line is a warning to pass on to the plugin author. Lint only proves that PHP can read each file. It does not call any function, so it cannot see the deprecated functions, the session change or the new ValueError cases.

5. Search for the functions PHP 8.6 deprecates. This reads the same copy with grep, so it needs no container. If the copy has a mu-plugins folder, add it after themes.

cd ~/php86-test/wp-content
grep -rnE --include='*.php' '\b(is_double|is_long|is_integer|doubleval|spl_object_hash|spl_classes|strcoll|metaphone|mysqli_get_charset|mysqli_stmt_init|mb_eregi?[a-z_]*|mb_split|mb_regex_encoding|mb_regex_set_options)\s*\(|SORT_LOCALE_STRING' plugins themes > ../deprecated.txt
wc -l < ../deprecated.txt
cut -d/ -f1-2 ../deprecated.txt | sort | uniq -c | sort -rn

Example output:

9
      6 plugins/example-shipping
      2 plugins/example-forms
      1 themes/example-child

The first number is the total of matching lines, and the list ranks the plugins and themes that own them. Open deprecated.txt to see each file and line. A count of 0 means none of these functions is called by name. A hit can also be a method that shares the name, so read the line. A real call logs a notice on 8.6 and keeps working.

6. Search for the two changes that show no notice at lint time.

grep -rnE --include='*.php' 'session_start\s*\(|session_set_save_handler\s*\(|\bdefine\s*\([^;]*,\s*(true|false)\s*\)\s*;' plugins themes

Example output:

plugins/example-shipping/rates.php:4:	define( 'EXAMPLE_RATES', 1, false );
plugins/example-shipping/session.php:2:if ( ! session_id() ) { session_start(); }

No output means neither pattern is in the copy. A define() hit needs the third argument removed by the author. A session_start() hit marks a plugin to test by hand once you have a staging site on 8.6. With the new defaults, the browser stops sending its session cookie on a form post that arrives from another site, and JavaScript can no longer read that cookie. A payment page or a single sign-on service that posts the visitor back to your site is the case to try. The plugin may be fine if it sets its own cookie options, or if the server’s php.ini sets these values, so the test decides. A session_set_save_handler() hit means a custom session store. PHP 8.6 logs a deprecation or a warning when that store lacks the create_sid() and validateId() methods.

7. Choose wait, test now or move.

DecisionIt applies whenWhat you do
WaitStep 2 finds no 8.6 package, or the WordPress table has no 8.6 columnStay on your branch and keep it patched
Test nowAlways, starting todayRun steps 3 to 6, update plugins, and report hits to their authors
MoveThe package is on your server, the WordPress table lists 8.6 for your WordPress version, and lint.txt has no Parse errorRun the site on 8.6 in staging first, then switch production

Run steps 3 to 6 again after each round of updates.

8. When the package arrives, run the site on 8.6 in staging. The checks above read code without running it, so they cannot replace a real run. The PHP 8.5 test loop covers the mechanics. It creates a staging subdomain, switches only that subdomain in MultiPHP Manager, logs the notices and rolls back. Follow it with ea-php86 in place of ea-php85.

Validate it works

Confirm that the test really ran on 8.6:

docker run --rm php:8.6-cli php -r 'echo PHP_VERSION, "\n";'

The reply must start with 8.6., for example 8.6.0.

Confirm that no file fails to parse:

grep -c 'Parse error' ~/php86-test/lint.txt

The reply must be 0.

Confirm that production is on a patched release of its own branch. Use the folder of your branch:

/opt/cpanel/ea-php84/root/usr/bin/php -r 'echo PHP_VERSION, "\n";'

For PHP 8.4, the reply must be 8.4.28 or newer. You now have a dated record of the server and WordPress status, a clean or explained lint.txt, and a ranked deprecated.txt.

Troubleshooting

Lint reports a parse error in a file that works today. Run step 4 again with php:8.4-cli, or the tag of your current branch, in place of php:8.6-cli. If the same error appears, PHP 8.6 is not the cause.

Most hits are inside a vendor folder. That folder holds libraries the plugin bundles, so the fix comes with a plugin update. Report the file and line to the plugin author.

Step 2 finds the package, but MultiPHP Manager does not list 8.6. A package the vendor has published is not yet installed on your server. Installing ea-php86 is a root task in WHM, under EasyApache 4. After that, the version appears in MultiPHP Manager for each account. On shared hosting, ask the host.

Staging on 8.6 shows no notices in any log. WordPress hides deprecation notices unless WP_DEBUG is true. The PHP 8.5 test loop shows how to send them to one file and how to prove the capture works.

When this is the wrong approach

If the site is still on PHP 8.2, PHP 8.6 is the wrong target. Security fixes for 8.2 end on 31 December 2026. Move to 8.3 or 8.4 now with the PHP 8.2 end-of-life plan, and come back to 8.6 later.

If the server is not cPanel and you install PHP from distribution packages, the status table above does not apply. Check your own package source, and use the PHP-FPM upgrade walkthrough for the switch itself.

A WooCommerce store should not move on these code checks alone. Place a test order on a staging copy running 8.6 before production changes.

Running WordPress that earns real money deserves an operator — Stack Harbor runs that stack under Enterprise WordPress; book an infrastructure consult.