WordPress PHP Versions: Best PHP for WordPress in 2023
Different WordPress versions can work with multiple PHP versions. Yet, the platform recommends specific PHP requirements for each WP version. Choosing the best WordPress PHP version is crucial to make sure that the website is secure and free of bugs.
This article discusses the compatibility between PHP and WordPress in terms of the recommended, minimum, and latest PHP versions for WordPress.
IMPORTANT: This article is being checked and updated regularly by our team to reflect the most accurate and up-to-date information. In case you found anything incorrect or inaccurate please don’t hesitate to contact us.
LAST UPDATED: May 04, 2023
In this article:
1. Overview
WordPress substantially relies on PHP to work and operate. Updates for both platforms are being published regularly to fix security loopholes and bring enhancements in usability and performance. Thus, WordPress users have to continuously update their software and confirm its compatibility with supported PHP versions.
WordPress PHP versions depend on the compatibility between WordPress and PHP. As each version of WP requires specific minimum PHP requirements. In this context, this article aims to explore the compatibility of the multiple versions of WordPress with PHP, in light of continuous updates being published on a regular basis for both platforms.
2. Supported PHP Versions
Updates of PHP programming language are being published regularly. The updates usually include bug fixes and security improvements besides other functional and performance enhancements.
When published, each PHP version remains supported for a period of 3 years from its initial stable release , the support period runs over two main successive phases:
- 2-Years Active Support: the support includes fixing BOTH BUGS and SECURITY ISSUES.
- 1-Year Security Support: the support includes fixing ONLY CRITICAL SECURITY ISSUES.
Once the support period is completed (after 3 years), the version reaches its end of life (EOL) and becomes no longer supported. It’s strongly not recommended to use an unsupported version of PHP as it might expose the application using it to security vulnerabilities and bugs.
3. WordPress Current PHP Versions
The official PHP website maintains a specific webpage to check the status of supported versions. Accordingly, the currently supported PHP versions that can be safely used for WordPress are:
PHP Version 7.4– No Longer Supported- PHP Version 8.0(Security Support, ends on 26/11/2023)
- PHP Version 8.1(Active Support, ends on 25/11/2023)
- PHP Version 8.2(Active Support, ends on 08/12/2024)
When an older PHP version runs out of support, it is removed from the list and, usually, a new version with full support is added.
4. WordPress PHP Requirements
In general, WordPress requires specific server requirements, which cover PHP requirements, hosting details, and other software dependencies.
Technically speaking, each version of WordPress has specific PHP versions that it is compatible with. That being said, although the software might work on legacy PHP versions that reached their End Of Life, the platform recommends using only supported PHP versions.
Important: a compatible PHP version is a version that WordPress requires to work properly, regardless of whether it is still supported or not.
Here is a list of the compatible PHP versions for each version of WordPress, knowing that we only consider WP versions that can work with the currently supported PHP versions:
To read our easy guide with pictures to finding PHP version in WordPress without a plugin please refer to this article. In case you are unable to access the admin control panel, you can find the PHP version by accessing your hosting cPanel or consulting your hosting service provider.
How to Check PHP Version in WordPress Without Plugin?
There are many ways to check the PHP version being used by a WordPress installation, usually using third-party plugins. In this article, we will find step-by-step how to check PHP version in WordPress without any plugin.
9. Conclusion
To avoid vulnerabilities and obtain the best performance for your website, WordPress and PHP versions should be always compatible with each other.
In this article, we discussed the PHP requirements of WordPress platform in terms of compatibility and possibly usable PHP versions.
- PHP Supported Versions: https://www.php.net/supported-versions.php
- WordPress Requirements: https://wordpress.org/about/requirements/
- WordPress Server Environment: https://make.wordpress.org/hosting/handbook/server-environment/
- PHP Compatibility and WP Versions: https://make.wordpress.org/core/handbook/references/php-compatibility-and-wordpress-versions/