Best PHP Version for WordPress in 2026: What to Pick
PHP 8.3 or 8.4 is the safe answer for most WordPress sites today. Here is how to check support dates, test your plugins and switch versions in cPanel without a white screen.

Infrastructure & Support Team
On this page
The best PHP version for WordPress today is PHP 8.3 or 8.4. Both are still supported by the PHP project, both work with current WordPress releases, and WordPress itself recommends 8.3 or newer. If your site is on 7.4 or 8.0, it is time to move; if it is on 8.3 or 8.4, you are in a good place.
The longer answer is "the newest version that every plugin and your theme run cleanly on". That is a testing question, not a guessing one, and the rest of this guide shows how to answer it in about an hour, including the exact cPanel steps to switch and roll back.
Which PHP versions are supported right now?#
PHP branches get two years of active support (bug fixes) and then two more years of security-only fixes. After that the branch is end of life and nothing patches it. According to the PHP supported versions page, as of this writing:
| Branch | Released | Active support until | Security fixes until |
|---|---|---|---|
| 8.2 | 8 Dec 2022 | 31 Dec 2024 | 31 Dec 2026 |
| 8.3 | 23 Nov 2023 | 31 Dec 2025 | 31 Dec 2027 |
| 8.4 | 21 Nov 2024 | 31 Dec 2026 | 31 Dec 2028 |
| 8.5 | 20 Nov 2025 | 31 Dec 2027 | 31 Dec 2029 |
Two things stand out. First, PHP 8.2 stops getting security fixes at the end of this year, so anyone still on it should plan a move soon. Second, anything older than 8.2 is already past the end of its life. Check the page itself before you decide, because dates and branches move.
What does WordPress itself say?#
The WordPress requirements page recommends PHP 8.3 or newer, with MariaDB 10.11+ or MySQL 8.4+ for the database. It still lists PHP 7.4 as the legacy minimum, but warns that 7.4 is end of life and may expose your site to security vulnerabilities. "Still starts" does not mean "safe to run".
The WordPress core team also publishes a PHP compatibility table. At the time of writing it shows WordPress 6.9 and newer working with PHP 8.0 through 8.5, while WordPress 6.6 covers 8.0 through 8.3 only. The takeaway: keep WordPress core updated, because an old core limits which PHP versions you can move to.
Best PHP version for WordPress: which one should you pick?#
A simple decision guide:
- PHP 8.3 is the conservative choice. Most mainstream plugins and themes have had a long time to catch up with it, and it has security support into late 2027.
- PHP 8.4 is a good choice if your plugins are actively maintained. It gives you the longest runway without being brand new.
- PHP 8.5 is worth trying on a staging copy, but expect a few plugins to lag. Core support does not guarantee that every plugin you installed three years ago works.
- PHP 8.2 is fine for a few more weeks, but it is on its last security-fix year.
- PHP 7.4, 8.0 and 8.1 are end of life. Move off them.
Newer versions are also usually faster per request than older ones, which is a free performance gain on top of the security benefit. How big the gain is depends on your plugins and database, so measure instead of trusting a headline number.
How to check whether your plugins will survive the upgrade#
Most upgrade breakage comes from abandoned plugins and themes, not from WordPress core. A quick audit:
- List what is installed. In the dashboard, open Plugins and Themes. Note anything without an update in the last year.
- Read the "Tested up to" and "Requires PHP" fields on each plugin's wordpress.org page. A plugin that says it requires PHP 7.2 and was last updated in 2021 is a risk.
- Remove what you do not use. Every inactive plugin is code you have to keep compatible and patched.
- Make a backup. Files plus database, stored away from the server you are about to change.
- Test on a copy. Restore the backup to a subdomain, switch only that copy to the new PHP version, and click through the front page, a post, checkout or contact forms, and wp-admin.
Add this to the copy's wp-config.php while testing, so deprecation warnings land in a log file instead of on screen:
define( 'WP_DEBUG', true );
define( 'WP_DEBUG_LOG', true );
define( 'WP_DEBUG_DISPLAY', false );Then read wp-content/debug.log. Deprecation notices are warnings about the future; fatal errors mean something will break today. Turn debugging back off on the live site afterwards.
How to change the PHP version in cPanel#
On a cPanel account the switch is a dropdown. LordCloud's PHP configuration doc covers the details, but the short version is:
- Log in to cPanel (see cPanel access if you need the login steps).
- Open MultiPHP Manager.
- Tick your domain, pick the PHP version from the dropdown and click Apply.
- Load the site and wp-admin straight away and check for errors.
If something breaks, go back to MultiPHP Manager and select the previous version. That is your rollback, and it takes seconds, which is why you do the change at a quiet hour with a fresh backup in hand.
Which versions appear in the dropdown depends on the server. If the one you want is missing, ask the host. If you are on shared hosting with an Indian provider, the support route matters: on LordCloud you can follow the support ticket guide.
Settings to review after you upgrade#
A PHP upgrade is a good time to check limits, because a new version can come with default settings that differ from your old ones. In MultiPHP INI Editor look at:
| Setting | Common value | Why it matters for WordPress |
|---|---|---|
memory_limit |
256M |
Page builders and WooCommerce can run out at 128M |
upload_max_filesize |
64M |
Media uploads |
post_max_size |
64M |
Must be at least upload_max_filesize |
max_execution_time |
120 |
Imports and backups need time |
max_input_vars |
3000 |
Large menus and settings pages |
Account plans cap what you can set, so you cannot raise memory_limit above what the plan allows. Also confirm the extensions your site needs, such as imagick, intl or sodium, are still enabled for the new version, because extensions are enabled per PHP version.
Fixing the usual post-upgrade errors#
- White screen or "critical error" message. Open
wp-content/debug.log, find the fatal error and the file path. The path names the plugin or theme at fault. Rename that plugin's folder over FTP or the File Manager to disable it, or roll back the PHP version first and then investigate. - Deprecated notices on every page. Harmless for now but a sign the plugin is ageing. Check for an update or an alternative.
- Missing image processing. The relevant PHP extension is not enabled on the new version. Enable it for that version in the extension selector.
- Slow wp-admin after the change. Clear any object or page cache, then test again. A stale opcode or page cache is common right after a version change.
A sensible upgrade routine#
Do not wait until a branch hits end of life. A routine that works: once a year, around the time the PHP project releases a new version in November, check the supported versions page, move to the branch that is one behind the newest, and keep WordPress core and plugins updated all year. Small yearly steps are far less painful than jumping from 7.4 to 8.4 in one go after years of neglect.
If you are choosing a host for a site like this, look for MultiPHP Manager access, current PHP branches and an easy way to restore backups. Our cPanel web hosting plans are built around that kind of control panel workflow, and our website migration guide covers moving an existing site. For the deeper server-side picture, the earlier post on Ubuntu vs Debian for a server shows how we think about picking stable, supported software.
FAQ#
What is the best PHP version for WordPress?#
PHP 8.3 or 8.4 for most sites. See the table above for support dates.
Is it safe to stay on an older PHP version if my site works?#
It works until it does not. An end-of-life branch gets no security patches, so a newly found vulnerability stays open on your server. Moving is cheaper than recovering from a hacked site.
How often should I upgrade PHP?#
Check once a year, and always before your branch loses security support.
Frequently asked questions
What is the best PHP version for WordPress?
For most sites, PHP 8.3 or 8.4. WordPress itself recommends 8.3 or newer, both branches are still receiving security fixes, and current WordPress releases support them. Pick the newest version that all your plugins and your theme run cleanly on.
Is PHP 7.4 still safe to use with WordPress?
No. PHP 7.4 reached end of life and no longer gets security fixes. WordPress still lists 7.4 as its minimum, but it warns that running it may expose your site to vulnerabilities. Move to 8.3 or newer.
Will upgrading PHP break my WordPress site?
It can, usually because of an old plugin or theme that uses removed functions. Take a backup, test on a staging copy or at off-peak hours, turn on WP_DEBUG, and keep the old version one click away in cPanel so you can roll back.
How do I change the PHP version in cPanel?
Open MultiPHP Manager in cPanel, tick your domain, choose the version from the dropdown and click Apply. The change takes effect straight away for that domain.
Should I use the very newest PHP version?
Not automatically. A brand-new branch is supported by WordPress core sooner than by every plugin. Wait until your plugins confirm support, or test first, and then move up.
References
Drafted with AI assistance and checked against LordCloud's published product information. Spotted a mistake?Suggest an edit.



