How to update PHP in WordPress?

If you own your web server, you can make changes yourself, but if you have hosted your website via a third-party then you need to contact them for making the required PHP changes. But having a third-party, it will not be your job to manage and maintain the updates, they will do it on their own whenever a new version update is available. Same goes with the plugins, themes, and PHP version.

Via cPanel
It also follows the same steps as login into your web hosting account. Then you can look for the software section where you can check the selected PHP version as shown below.

Click it and you can see the next page displaying the PHP version. From there, you can select the latest version for the PHP as shown below.

You can follow the below-mentioned simple steps to check the PHP version.
You can look for the plugin “Display PHP Version” and install it. You can find it in the WordPress repository as shown below.

You can now activate the plugin. Then navigate to the WordPress dashboard-> home-> at a glance.
You will be redirected to the new page where you will be able to see the PHP version on which your website is running.

click the Update option available.

Contacting host provider
If you are using a third-party for hosting your website, then you need to contact them for making the required changes. These host providers have skilled persons for making such changes either via code or via interface depending on the changes.