Dev.to Security πŸ” Cybersecurity πŸ‘ 2 πŸ“– 1 min read

End-of-life PHP: how to check your host's version

An end-of-life PHP branch no longer receives security fixes. The official table is at https://www.php.net/supported-versions.php. At the time of writing it lists these security-support end dates: PHP 8.2 on 31 Dec 2026,

An end-of-life PHP branch no longer receives security fixes. The official table is at https://www.php.net/supported-versions.php. At the time of writing it lists these security-support end dates: PHP 8.2 on 31 Dec 2026, 8.3 on 31 Dec 2027, 8.4 on 31 Dec 2028 and 8.5 on 31 Dec 2029. Always recheck the table: it is the source of truth.

Find your version

  • WordPress: Tools, Site Health, Info tab, "Server" section shows the PHP version.
  • WP-CLI: wp cli info prints the PHP binary and version.
  • Shell access: php -v.
  • Hosting panel: cPanel "MultiPHP Manager", Plesk "PHP Settings".
  • From outside: curl -sI https://yourdomain.com | grep -i x-powered-by. Many hosts hide this header, so no result proves nothing.

Note that the command line PHP and the web PHP can differ. Trust the panel or Site Health for the version serving your site.

Compare

Open the php.net table and check your branch (8.2, 8.3...). If your branch is not listed in the supported table, or its security support date has passed, plan an upgrade.

Upgrade without a bad surprise

  1. Back up files and database.
  2. Update WordPress core, themes and plugins first.
  3. Create a staging copy, switch it to the new PHP version in the panel, and read the PHP error log.
  4. Fix or replace plugins that throw errors (deprecations are common between minor versions).
  5. Switch production at a quiet hour, keeping the previous version selectable for a quick rollback.

Ask your host if you cannot choose the version yourself.

Check your own domain

If you would rather not run these commands by hand, there is a free check at https://attackscout.com/en/deadlines/php-8-2-end-of-life?utm_source=devto&utm_medium=article&utm_campaign=eol-php-8-2

πŸ“° Read the original article on Dev.to Security

Originally published by Dev.to Security. Aggregated on AIWithGhost for educational purposes β€” full credit and traffic to the original publisher.