WordPress.org Now Allows Plugin Authors to Specify a Minimum PHP Version Requirement

Although WordPress core currently maintains backwards compatibility with PHP 5.2.4+, plugin and theme authors are not required to do so. When developers include features that require more recent versions of PHP, it can break sites or cause otherwise unexpected behavior. As part of a larger effort to encourage users to upgrade their PHP versions, WordPress.org now allows plugin authors to specify a minimum PHP version requirement in the readme.txt file with a new Requires PHP header. It is displayed to users in the sidebar of the plugin’s description:

This addition to the readme.txt file has been well-received by developers who are already updating their plugins in the directory with minimum PHP version requirements. It also complements WordPress’ Core PHP team’s recent efforts to educate users about the benefits of upgrading PHP, as the minimum supported version was released 10 years ago and hasn’t received security patches for nearly seven years.

“As a plugin developer (who maintains my plugins in my spare time), it is becoming increasingly difficult to build new functionality that works in older versions of PHP,” Paul Gilzow commented on the announcement. “There are some things that simply cannot be done in the older versions, and in those cases, I have to build out functionality to check PHP versions and disable those features. That takes time and energy away from building out other new features.”

WordPress Core Committer Sergey Biryukov said the next step is exploring the possibility of displaying a notice to users when they cannot install a theme or plugin due to their installations not meeting the required criteria. Ideally, these notices would include host-specific instructions to assist users in getting their sites upgraded to a newer PHP version. This particular move could make a significant impact on the wider WordPress community, if popular plugins start triggering notices requiring newer versions of PHP.

Would you like to write for WP Tavern? We are always accepting guest posts from the community and are looking for new contributors. Get in touch with us and let's discuss your ideas.


  1. A very helpful effort that’ll benefit users and developers. Thanks for the good news.


  2. Great beneficial addition and badly needed! I like Sergey’s suggestion too!


  3. This is so great! PHP version has been a pain in plugin development for a long time!


  4. Great idea. I just updated one of my plugins with the minimum PHP version (required due to closures in the code).


  5. Great addition…!!
    feel happy to heard this..Hope it will help the users and developers..
    thanks Sarah for sharing the post..


Comments are closed.