Blog / Web management /

Upgrading PHP on WordPress safely

The hosting dashboard says a newer PHP version is available. One click, surely?

Not quite. The site has a theme, plugins, scheduled jobs and maybe a checkout someone relies on. Change the runtime without a plan and a routine task becomes a support incident.

PHP upgrades matter for security, support and compatibility. The safe route: know what the site uses, confirm what your host offers, test the workflows that matter and keep a way back. The exact steps depend on the host and PHP version, so follow the provider’s documentation and don’t paste a command written for another server.

Find out what is running now

Check the current PHP version in the hosting panel or WordPress Site Health. Confirm whether the site runs on managed WordPress hosting, a shared plan, a virtual server or a custom environment. Different hosts expose different controls, and some apply changes across an account rather than one site.

Before any PHP change on a client site, I list the WordPress core, theme and plugins: what’s active, when it was last updated and what business function it supports. Pay attention to payment, forms, membership, multilingual and page-builder components. A theme can also bundle older libraries or custom code that does not appear in the plugin list.

Review the host’s supported versions, scheduled changes and backup policy. Ask whether a PHP change affects other sites on the account and whether the old version can be restored temporarily. A host offering backups doesn’t mean a usable backup exists. Find out how to request a restore and how long it takes.

Check compatibility evidence

Read release notes from the theme and important plugins. Look for PHP compatibility statements and known issues. A plugin that hasn’t been updated lately isn’t automatically broken, but it needs attention if the site depends on it. If the information is unclear, ask the maintainer or the host.

Use staging where possible. Copy the site without exposing private data unnecessarily, change PHP there, then test the front end and administrator area. Check a representative post, a form, navigation, search, and ecommerce actions where relevant. The homepage loading proves nothing about the checkout, a scheduled task or a PDF export.

Watch for warnings and errors in logs. A deprecated function notice may not immediately break the site, but repeated warnings can indicate that code needs attention. A fatal error or blank page points to a more urgent compatibility problem. Capture the message and identify the component before applying fixes.

Plan the change and its rollback

Choose a maintenance window when the responsible person is available. Tell stakeholders what may change and when it will be checked. Take a verified backup of files and database before switching the live version. If the host supports a one-click restore, know which restore point it will use and whether it also rolls back recent orders or content.

Change one environment at a time. If several sites share a hosting account, do not update every site at once unless the provider confirms the scope and the team has tested each configuration. Keep a change log with the time, PHP version, host action, tests performed and any issue observed.

If staging cannot be used, reduce the uncertainty before proceeding. Confirm the backup, review compatibility information, test the most important workflows and coordinate with hosting support. For a high-risk ecommerce site, ask the site owner to approve the timing and recovery plan.

Verify what customers use

After the live change, open the site in a fresh browser session and test the functions that matter. Check key pages, forms, login, search, checkout, payment status notifications and scheduled tasks where possible. Review logs and monitoring for new errors. If a cache is involved, clear it using the approved process and retest.

If something fails, don’t start changing unrelated settings in a panic. Work out whether you can revert PHP and whether the error points to a plugin, theme or server extension. Tell the owner what is known and what remains under investigation. An update that requires a rollback is not a reason to hide the event; a clear record helps prevent the same surprise later.

Keep the version current over time

A PHP change should be part of an ongoing maintenance plan, not a one-off scramble. Track which sites are approaching unsupported versions and who owns compatibility checks. Keep WordPress and extensions maintained as well, because an old theme can become the bottleneck even when the server is current.

Avoid making a specific security or speed promise from the version number alone. The application, configuration, hosting and workload all contribute. A newer runtime may improve the environment, but a slow query or third-party script can remain slow.

Managing several client sites at Nivonix, checking hosting and application dependencies is part of keeping them running. I don’t try to memorise one upgrade command. I make sure there’s enough documentation and access to make the change safely.

When a plugin has no clear compatibility answer

Do not assume that silence from a plugin author means the extension will work. Check the release history, support channel and whether a maintained replacement exists. Test the site with the extension in staging, including the feature it provides. If the plugin is abandoned and business-critical, plan a replacement before changing the production runtime. If it is unused, remove it through a controlled process and check for data or shortcodes it may have left behind. The decision belongs with the site owner, informed by evidence and a recovery option.

Check one site’s PHP version, backup process and rollback option today. Who would verify the site after the host makes the change?