How to downgrade or upgrade to PHP version
Introduction
In some cases, you may need to change the PHP version running on your WordPress site for compatibility reasons. This guide will show you how to both downgrade and upgrade the PHP version using the Staq Panel.
Downgrading PHP Version
To downgrade your PHP version, follow the steps below:
- Log into your site’s Staq Panel.
- Click on PHP Config.
- Under the PHP version dropdown, to downgrade from v8.x down to 7.4, select 7.4.
- Once selected, scroll down and click Save.
After saving, your site will automatically be downgraded to the selected PHP version.
Upgrading to PHP8
It is very simple to upgrade to PHP8 inside Staq. Follow the steps below:
Step 1
Go to the website’s Staq Panel and click on PHP Config:
Step 2
To avoid spinning up a staging website, Staq has built a PHP compatibility feature. To access this feature, under **PHP version**, click **8.2** and below, you should see Test PHP version compatibility:
Step 2.1
The tool will run and assess the code’s syntax for both plugins and themes (both active and deactivated plugins and themes).
If the site isn’t ready to be upgraded to PHP 8.2, it will show what plugins or themes are preventing the upgrade:
To resolve this, update the identified plugins or themes to their latest versions.
Step 2.2
If your site is ready to be upgraded to PHP 8.2, you will receive a success message:
Step 3
Click Close after verifying compatibility and ensure that the desired PHP version remains selected.
Scroll down and click Save.
The upgrade will be applied shortly.
Step 4
To verify that your site is running the desired PHP version, log into the WordPress website and click Staq Hosting > Advanced > PHP version:
Conclusion
By following these steps, you can easily downgrade or upgrade the PHP version on your WordPress site using Staq Panel. Always ensure that your site’s plugins and themes are compatible with the PHP version you select, and if you run into any issues, feel free to contact our support team for assistance.
Need some help?
We all do sometimes. Please reach out to our support team by dropping us a support ticket. We will respond fast.