How to update your PHP version

To update PHP, switch your site to PHP 8.4 or 8.3 (latest releases 8.4.28 and 8.3.37, out Nov 19, 2026) in your hosting panel, or install the new packages on your own server, then restart PHP and test the site.

Start by finding what you run now with our free PHP version checker. Sites on PHP 8.2 to 8.5 also need the October 2026 release for PHP2Shell (fixed versions here).

Check your current PHP version

Read-only: one standard page request, like a browser visit. We never send attack traffic.

How to check your PHP version

For PHP2Shell, compare the result with the fixed releases below, or for a distribution package, with your distribution's tracker (Ubuntu, Debian, Red Hat).

Which version to update to

VersionLatest releaseSecurity fixes until
PHP 8.58.5.13Dec 31, 2029
PHP 8.48.4.28Dec 31, 2028
PHP 8.38.3.37Dec 31, 2027
PHP 8.28.2.36Dec 31, 2026
PHP 8.1 and olderNo fixesEnded

For most sites, PHP 8.4 or 8.3. PHP 8.2 stops getting security fixes on Dec 31, 2026, so moving to it now means moving again soon. Full dates: latest PHP version and end-of-life dates.

Before you switch

  1. Back up the site's files and database, or confirm your host's backup from today exists.
  2. Update plugins and themes first. Old versions are the usual reason a site breaks on newer PHP.
  3. Use a staging copy if your host offers one, and switch that first.

Shared hosting with cPanel

  1. Log in to cPanel and open MultiPHP Manager. Some hosts call it Select PHP Version.
  2. Tick your domain, choose PHP 8.4 or 8.3 from the list, and click Apply.
  3. Load the site and test the home page, login, contact form and checkout.

If you're already on PHP 8.2 to 8.5, the panel only picks the branch; the host installs the patch releases. Ask support whether 8.4.28 (or the fixed build for your branch) is in place.

Plesk

  1. Open Websites & Domains, then your domain, then PHP (or PHP Settings).
  2. Pick PHP 8.4 or 8.3 and the handler your site already uses (usually FPM), then save.
  3. Whoever runs the server keeps the PHP builds themselves current, under Tools & Settings, Updates.

Managed WordPress hosts

Hosts that manage PHP for you usually install patch releases themselves and give each site a PHP version setting in their dashboard. Change the branch there, then test. Host by host: how to change the PHP version WordPress runs on.

Ubuntu or Debian server

Patch releases within your branch come through your normal package updates. PHP says Linux distributions received the PHP2Shell patches in advance, so their packages may keep the old version number with the fix added.

sudo apt update
sudo apt upgrade              # installs your distribution's PHP fixes
sudo systemctl restart php8.4-fpm   # your branch; restart Apache instead if it runs mod_php

To move to a new branch, install its packages next to the old ones, point the web server at them, and remove the old ones once the site works:

sudo apt install php8.4-fpm php8.4-cli php8.4-mysql php8.4-xml php8.4-mbstring php8.4-curl
# Nginx: set fastcgi_pass to unix:/run/php/php8.4-fpm.sock, then
sudo nginx -t && sudo systemctl reload nginx
# Apache with PHP-FPM:
sudo a2disconf php8.1-fpm && sudo a2enconf php8.4-fpm && sudo systemctl reload apache2

If apt doesn't offer the branch you want, your distribution doesn't package it. Use the PHP repository your server already uses, or ask your provider. Install the same extensions you had before; php -m on the old version lists them.

Docker

  1. Change the base image to the branch you want, for example FROM php:8.4-fpm or FROM php:8.4-apache.
  2. Rebuild with docker build --pull so Docker fetches the current image instead of a cached one with old PHP.
  3. Redeploy, then check the version inside the running container with php -v.

After the update

Confirm the version the web server actually serves, not only php -v: the two can differ. Run the checker above again, or look in WordPress under Tools, Site Health, Info, Server.

Want to know the day it matters? Continuous monitoring reads the real PHP version from inside your server every day and emails you the day a new fix applies to your site, plus the signs of a break-in. See pricing.

Get told when to update

Questions

How do I check my PHP version?

In WordPress, Tools, Site Health, Info, Server. In cPanel, MultiPHP Manager. On a server, php -v, plus your package manager for the installed package version. From outside, our free checker reads the version a site reports.

Which PHP version should I update to?

PHP 8.4 or 8.3. Their latest releases are 8.4.28 and 8.3.37 (Nov 19, 2026), and they get security fixes until Dec 31, 2028 and Dec 31, 2027. PHP 8.5 is the newest branch (8.5.13); check your plugins support it first.

Will updating PHP break my site?

It can, if a plugin, theme or custom code relies on something the newer PHP changed or removed. Back up first, switch, and test the home page, login, forms and checkout. If something breaks, switch back and update or replace the part that failed.

Does updating WordPress update PHP?

No. WordPress, plugins and themes run on PHP, but PHP is installed by your host or on your server. You change it in your hosting panel or with your server's package manager.

Do I need to restart anything?

Yes. PHP-FPM and Apache keep running the old PHP until they restart. Hosting panels restart for you when you switch versions; on your own server, restart PHP-FPM or Apache yourself.

How do I know the update worked?

Check the version the web server actually uses: WordPress Site Health, a phpinfo page you delete afterwards, or our free checker. php -v on the command line can show a different PHP from the one serving your site.