Anyone who is using WordPress platform for building blogs or Websites are already using PHP. Chances are you may never need to learn anything about PHP because everything happens at the backend. With the help of plugins (which all uses PHP) we can add functionalities to WordPress without even editing code.
In December 2015, PHP version 7 was launched & if you hear carefully, you would notice almost all the popular WordPress hosting companies like SiteGround, Bluehost are shifting to PHP 7. As an end user PHP version really matters as it can speed up your blog by a considerable amount.
In this article you will learn a bit about PHP versioning & how to check PHP version of your hosting. This is useful even for non-technical user as it would help you to improve the overall performance of your WordPress blog. Also, if you are planning to switch hosting in coming days, the supported version of PHP is going to be another deciding feature for your purchase.
Before the launch of PHP 7, almost all the hosting were using PHP version 5.6 or earlier. In fact, chances are right now your WordPress blog is on a hosting that is offering PHP 5.6. PHP 7 is a considerable performance improvement over PHP 5.6. According to tests, PHP 7 makes your pages load almost half the time.
This could be clearly seen in the test done by Kinsta hosting where they used dummy content from wptest.io and benchmarked the home page for a minute with 15 concurrent users.
- WordPress 4.3.1 HHVM RepoAuthoritative benchmark result: 375.48 trans/sec
- WordPress 4.3.1 HHVM benchmark result: 357.69 trans/sec
- WordPress 4.3.1 PHP 7.0 benchmark result: 306.24 trans/sec
- WordPress 4.3.1 PHP 5.6.16 benchmark result: 106.45 trans/sec
Similar results were found when using other CMS like Drupal, Magento & others. In nutshell, if your hosting offers you the option to use the latest version of PHP, you should switch to PHP 7. I would be writing guide on how to switch PHP version on different hosting in coming days, but for now what you need to find out is: What version of PHP are you running your WordPress blog on?
How to find out what version of PHP your WordPress site is on?
This is the simplest plug & play plugin that shows you the current PHP version your web-hosting is running WordPress on. You can search fro “Display PHP Version” from WordPress dashboard & install the plugin. Here is the official download link of the plugin.
Once you have this plugin activated, simply go to WordPress dashboard & you would be able to see the version of PHP under “At a glance” section. (See the below screenshot for better understanding).
In the above screenshot it’s a test blog hosted on Bluehost hosting which is currently running on PHP version 5.6.29.
Using the same plugin you can find the PHP version on any web-hosting that you are using. From here, the next step is to switch the PHP version to PHP 7. However, before you do that, one thing you need to ensure that your plugins & themes are compatible with the PHP 7. Else, your site might break.
If you are using plugins & themes that are regularly updated, you will have no compatibility issues, else this might break your site. If that happens, you don’t need to worry much as you can also downgrade your PHP version with few clicks & your site would be backed up. As I said, this may or may not happen so your best bet is to switch your hosting PHP version to PHP 7 & hope it works.
PHP Compatibility Checker WordPress plugin
If you want to take the guess work out of the equation, you can use PHP Compatibility Checker WordPress plugin which is developed by guys from WPEngine WordPress managed hosting.
This plugin will lint theme and plugin code inside your WordPress file system and give you back a report of compatibility issues for you to fix. You can use the plugin by going to tools > Compatibility & configure using below settings.
Click on scan site & it would display results in minutes. Here is what I got when I used PHP 7 compatibility checker WordPress plugin:
Thats means all my plugins are compatible with PHP 7 & I can upgrade my PHP version. It’s your turn to run the same test & see if all your plugins & themes are compatible or not. If any of the plugin is not compatible, you should consider losing it before changing PHP version to PHP 7.
PHP 7 offers considerable speed improvement over its predecessor. If your hosting offers feature to use PHP 7 & your WordPress plugin/themes are compatible, you should definitely upgrade. Make sure to run a speed test before & after to notice the difference in speed & overall performance.
ShoutMeLoud is hosted on Kinsta hosting & we are already using PHP 7 from past few months. It’s your turn to let me know what hosting are you using & which version of PHP your WordPress site is using? Let us know in the comment section below.