I have a plugin that previously supported PHP 5.6. The new upcoming version supports 7.4 and higher.
Does WordPress automatic update take that into account when automatically updating plugins? Or will it just update and break the website that is on PHP version lower than 7.4.
Tried googling it but can not find an answer anywhere.
2
Answers
From personal experience, WordPress does not really care. Depending on the plugin, it might be deactivated or just run and break your site. It might still work, but it might be a safe bet to disable the auto update and verify yourself if the plugin is compatible. You can create your own local testing environment with for example, local flywheel.
For anyone still looking for an answer to this, WP has code that prevents auto-updates. Not only that, but apparently WP also prevents any type of plugin update (not just auto-updates) if your plugin has a "Requires PHP" header, and your PHP version is lower than that.
This are a few tickets covering this:
That being said, I still make sure that I pin a topic at the top of my support forum, and I add upgrade notices. I have had a few cases back in 2020 when I dropped support for PHP 5.3.x the right way, and yet I had users’ sites break. This sometimes happens if the hosting platform does something funky.