* The .htaccess file will not be supported in PHP 7.4. We will continue support your .htaccess as normal on all previous versions of PHP until they are deprecated. For more information and alternatives to .htaccess directives, check out our .htaccess deprecation guide here.
When it comes to security and speed, upgrading PHP versions is a straightforward and invaluable way to “Press Ahead” of your competition. We recommend using our PHP Test Driver to preview their site on a new PHP version. Once that compatibility check is complete, you can simply select your desired PHP version with the PHP Selector tool. No migration required. It’s as simple as that!
Why upgrade PHP
PHP is a flexible web development language that WordPress, and many other web platforms, run on.
PHP is managed by a third party team of developers from around the world who maintain, update and correct the language in stable version releases.
Upgrading your PHP is a lot like updating plugins or themes; it makes your site perform better and run more securely.
Each PHP version is supported for 2 years after the initial release date, to receive improvements, bug fixes and security patches. After those first 2 years a PHP version will only receive critical security updates, as-needed. After 3 years, the PHP version is deprecated and no longer receives updates, making it not supported and insecure.
At WP Engine we want you to have the fastest and most secure WordPress hosting experience. One of the most easily changed factors to improve your site’s performance and security is the PHP version.
For example, in upgrading a website on WP Engine from PHP 5.6 to 7.2 we saw speed improvements of up to 40%. From 7.2 to 7.3 we’ve seen as much as 15% faster page transaction times. Now, with 7.4, we have seen around 10% performance improvement after upgrading.
Automatic PHP Upgrades
The EOL (End-Of-Life) process is a standard part of the release cycles of PHP (the open source programming language which powers WordPress). Once a version has reached “end of life”, PHP ceases to provide security support for it and it is no longer secure enough to remain on WP Engine servers.
For security purposes, WP Engine completely removes older versions of PHP from our servers once they have reached “end of life”. At this time, if your website is using an older version of PHP, it will be upgraded to a newer version automatically.
Our team will notify you via email several times before this automatic change occurs. We highly recommend updating as soon as possible when a new PHP version is released to ensure your site is receiving performance benefits as well as to ensure you can perform the upgrade in a suitable window for your needs. Automatic PHP upgrades cannot be deferred.
NOTE: Ensure your Technical Contact is up to date to receive PHP upgrade notifications.
Supported PHP Versions
7.2 (EOL 2020) 7.3 7.4
If a new PHP version is not available for your environment, it will be soon. We roll out all new versions slowly to the WP Engine farm as a security precaution. If you’d like a new version more quickly, a migration may be necessary. In most cases it’s considered easiest to simply wait for the rollout process to complete.
WP Engine is doing away with the
.htaccess file with the upgrade to PHP 7.4. This may sound intimidating, but no worries! We will continue support your
.htaccess as normal on PHP 7.3 until that version is officially deprecated. You’ll have ample time to work with us to get your site functioning without the file.
For more information and alternatives to
.htaccess directives, check out our .htaccess deprecation guide here.
Checking current PHP version
There are several options to check the current PHP version on a WordPress website:
- The easiest way to see the PHP version on an environment is to view the current setting of the PHP Selector
- Create a PHP Info page for the environment
- Use a plugin such as Display PHP Version to show the current PHP version from within the WP Admin
Changing PHP version
Changing PHP versions is quick and easy, requiring no technical knowledge. Simply change PHP versions of an environment with either of our PHP Selector features in the User Portal.
Changing PHP versions is easy and free for all plan types. You can also have multiple PHP versions across different environments on your account. This means you can get your websites upgraded as they’re ready, rather than updating the entire account at once.
NOTE: PHP 7.4 has deprecated the .htaccess file. Read more here.
You can upgrade or downgrade between any of the available PHP versions in the PHP selector as-needed. Once a version is retired from WP Engine servers, however, your website will be automatically upgraded to a newer version. We recommend upgrading to each new version of PHP as soon as possible.
A PHP version change does not require downtime on WP Engine and no DNS updates are needed. PHP version selection is an immediate, in-place change and the PHP Selector simply switches your environment to the chosen PHP version. We do recommend testing the site first to ensure there will be no errors preventing the site from working on a new PHP version, however.
Testing a new PHP version
There are several options for testing prior to upgrading a live site:
- Use the PHP Test Driver
- Copy to a Staging or Development environment and upgrade PHP independently
- Each environment can have a different PHP version using the PHP Version Selector
- Run our PHP Compatibility Checker plugin
You may see some “Deprecation” notices in your Apache error logs following your PHP upgrade. In this sense, “deprecated” refers to PHP features that are being replaced by different, updated features. With every new PHP version, there are some deprecated functions and elements. These aspects of your website will work for now, but will be removed in later versions of PHP, giving developers time to update their code. You can find a list of deprecated features, as well as their recommended modern solutions, on the PHP website.
Troubleshooting PHP errors
In some cases, a PHP upgrade may break your website. If the previous version of PHP is still available on the server, the PHP selector can be used to switch back temporarily. We highly advise reaching out to your plugin/theme authors or a developer for guidance resolving errors, as switching to an older PHP version is not a permanent solution.
- Copy to staging/development environment
- On a test environment, upgrade plugins, themes and WordPress core files
- Many premium themes and plugins will not show an update available in the WP Admin, so be sure to check with the author directly
If you still have issues, you will need to start ruling items out in order to locate the culprit:
- Disable plugins one at a time
- Enable a default theme
- Reinstall default WP Core files
- Test with a default .htaccess file
Additional troubleshooting options:
- Accessing server’s PHP error logs
- Understanding PHP error messages
- Resolving a 500 internal server error
- Troubleshooting using SSH Gateway
Need development help?
If you still need guidance for determining which item(s) may be causing errors, reach out to our Support team.