How To Update PHP Version in WordPress (cPanel, Bluehost, Kinsta)

We always keep our WordPress core up-to-date, as well as your plugins and themes. It is an essential part of website maintenance. Doing so can help you avoid security vulnerabilities and protect your data. But when it comes to updating your PHP version, we often don’t pay attention to that. WordPress runs on PHP, so it’s important to update your PHP version to the latest one.

Although WordPress technically works with some older versions of PHP, you may sacrifice security, performance, and compatibility. That’s why you need to learn how to update PHP in WordPress. And the good news is that updating the PHP version isn’t a difficult process. There are several methods you can use to do that.

In his article, we will briefly discuss why it is important to update to the latest PHP version, and how to check which PHP version your site is using. And lastly, we will show you a few options to upgrade the PHP version.

Why You Should Update Your PHP Version in WordPress?

The three main reasons to update to the latest PHP version are:

Security:

To safeguard your website from hackers, upgrading to the latest version of PHP is a must. Hackers exploit outdated versions of PHP to hack into sites, updated PHP version lessens the chances of hackers gaining access to your website. Also, the newer versions are always launched to remove the shortcomings and flaws in the earlier versions. They introduce patches, bug fixes, and security features that can help protect your website against viruses, malware, hackers, and many other digital threats.

Speed and Execution:

Updating to a new version of PHP can make your website run up to 4 times faster. Each PHP version improves performance by more efficiently running processes and reducing memory usage.  They not only reduce the latency time but also boost the speed of loading and processing requests received in a second. And we all know a faster website means a higher ranking in search results, improved user experience, and more sales!

Compatibility:

Using an older PHP version may result in errors and hurt the performance of your website. If you are running on an older PHP version, then you will see plugins and themes becoming incompatible. So, for the smooth operations of your plugins and themes, the latest versions are required.

How to Check the Current Using PHP Version?

If you need to update your PHP version or not it depends on which PHP version you are currently using. Normally, WordPress hosts automatically update the PHP version in the background. These updates do not affect most websites, and you may not notice any change at all. That’s the reason checking your current PHP version before updating is a must.

 There are lots of ways to check your current PHP version, you can check it from your WordPress admin area, from cPanel, from your hosting account, or by using a plugin. We will talk about the easiest one, which is from your WordPress admin area. To check, first navigate to “Tools > Site Health” and switch to the “Info” tab.

check your php version

Here, you will find a handful of information about WordPress, Directories & Sizes, Server, Database, etc. Expand the “Server” tab, it will show you all the server information including the current PHP version you are using.

check your php version

Steps To Take Before Updating Your PHP Version:

Though there are lots of benefits to updating PHP versions, there are some risks associated with it also. One of the most common risks is that the code used in core, scripts, themes, and plugins might not be compatible with the latest version. This can result in breaking your WordPress site. But the good news is those risks can be prevented by following some steps. It will decrease the chance of running into any trouble.

1. Create a Backup of Your WordPress Site:

Create a complete backup of your WordPress site before updating your PHP version. In the unlikely event that something goes wrong, creating a backup ensures that you have something to revert to.

2. Update WordPress Core, Themes & Plugins:

If you are running on an outdated version of WordPress and you update to the latest PHP version, it could cause incompatibility issues and render your site unusable. The same goes with themes and plugins, if you’re using third-party WordPress themes and plugins, there’s no guarantee they’ll be compatible with every version of PHP. So, we recommend visiting your “WordPress admin dashboard > Updates” before updating the PHP version. You can view all the available updates there. If updates are available, then make sure you update all of them first.

3. Check PHP Compatibility:

There is no guarantee that your WordPress site will run smoothly even if you have updated your WordPress core and all the themes and plugins. You should test your themes and plugins against various versions of PHP, using the free PHP Compatibility Checker. But how can you do that?

There is a free WordPress plugin, called PHP Compatibility Checker. Install and activate that plugin first.

check php compatibility

Once it is activated,  navigate to “Tools > PHP Compatibility”, select the version of PHP that you are planning to upgrade to, and choose “Only scan active plugins and themes” or “Scan all plugins and themes” option, then press the “Scan site” button.

check php compatibility

If you find any compatibility issue with any theme or plugin, contact the developers and ask them to investigate the issue.

Now, you have taken all the required steps one should take before updating your PHP version in WordPress.  So, let’s move on to the main part of this article, which is updating the PHP version.

Updating the PHP Version on Your WordPress Site:

However, there is no option to update your PHP version on your WordPress dashboard. But you have several methods to update it, as all the top WordPress hosting companies allow you to do so. cPanel is a generic dashboard for managing your site but some hosts provide their custom dashboard to update PHP in WordPress.  So, in this section, we will show you how to update your PHP version using cPanel and two different hosting providers’ custom dashboards, which are Bluehost and Kinsta.

You don’t need to worry if you are using any other hosting service.  Depending on the hosting service you are using it can be slightly different but they will be more similar, relatively quick, and straightforward.

cPanel:

If your hosting provider uses cPanel, updating your PHP version should be a quick and straightforward process. Here, you should find a section called Software, where there is an option “Select PHP Version”.

update php in wordpress

On the next screen, you will see your website’s current PHP version. Click on the drop-down next to the current PHP version and select the latest one from a list of all available PHP releases.

update php in wordpress

In this case, the list goes up to 8.0. Once you’re done, click “Set as current”, and cPanel will do the necessary.

So, here you switched your PHP version within a few clicks.

Bluehost:

To get started, log in to your Bluehost account dashboard and click the “Advanced” tab from the side navigation menu to the left. This will redirect you to the advanced tools page. Scroll down and search the “MultiPHP Manager” option.

update php in wordpress

On the next page, check the domain name you want to change the PHP version of and select the version of PHP you would like to use.

Click “Apply” to finish the update and you are done!

Kinsta:

With Kinsta, you can update PHP in WordPress in about three clicks. First, log into your MyKinsta dashboard, select the site, and go to the Tools tab. On the Tools tab, there are a bunch of ways to change certain aspects of your server.

update php in wordpress

Now, scroll to the PHP engine icon, you will see your current version of PHP. Here, click the Modify drop-down menu, and choose your desired PHP version.

Once you make a new selection, this will bring up a dialog box asking for a confirmation. Click on the Modify PHP version to continue.

Once you confirm, Kinsta will take several minutes for your hosting provider to complete the PHP updating process. Make sure you don’t exit the screen before it’s finished to avoid causing errors. It will take up to 3 minutes, and you are all set!

Conclusion:

PHP not only plays an important role in running your WordPress Website but also ensures the performance, security, and compatibility of your site. Now that you are clear about how to change the PHP version, don’t waste time and start getting those advantages. If you have any questions about updating your WordPress PHP version, let us know in the comments section below! We appreciate further comments, support, or suggestions!

If you find this article helpful, check our Blog post page to get more articles like Setting Up HTTP Security Headers on Your WordPress and How To Block IP Addresses for Better Security in WordPress. Also, don’t forget to subscribe to our YouTube channel and Facebook page.


Leave a Reply