WordPress resource site for WordPress Beginners with easy to understand WordPress tutorials for mastering the basics and beyond.

WordPress Guide

WordPress Guide

Your php installation appears to be missing the mysql extension which is required by wordpress.

  • Your PHP installation appears to be missing the MySQL extension which is required by WordPress.
  • Let’s dive right into what you need to do to remove that error.
  • You’ll need admin level access to your WordPress website, as well as access to the hosting account for this site or FTP access.
  • So first things first we need to check what PHP version you’re using.
  • I’m going to use the free compatibility checker plugin.
  • If your website is using PHP 7.1 or higher, and you’re seeing this error, it means that you have to update your WordPress version and plugins.
  • To update WordPress go to the dashboard and go to updates.
  • If you see a button that indicates your WordPress core version needs updating, click it.
  • If you don’t, click check again and re-install now, just to be sure.
  • Now check your site.
  • If the error message isn’t gone, you’ll need to verify whether or not the MySQL extension is installed and enabled.
  • Access your website’s files either with the file manager in your hosting account or through FTP.
  • Create a new file called info.php in the root directory or public HTML area.
  • It should look something like this.
  • In the file that you just created add this snippet of code.
  • Save the file, and then in your browser type in your website’s domain name, and then add forward slash info.php to the end of it.
  • You’ll be able to see a page full of detailed information about your PHP install.
  • If the MySQL extension is installed properly it will display a version next to your client API, and it’ll look something like this.
  • If it’s blank the extension is not installed.
  • The steps to install it can vary depending on your host, and your systems.
  • For detailed guidance you can refer to the PHP documentation and installation guides, which are linked in the description box below. If the issue still isn’t fixed, it’s likely that your PHP extension directory is not configured properly or at all.
  • Go back to the PHP info page in your browser to check by looking for loaded configuration file.
  • This is where you’ll find the file path value, and it’ll look something like this.
  • Next, locate the extension underscore dir parameter.
  • The entry should match the loaded configuration file path that you just saw.
  • If yours is pointing toward an incorrect location you’ll need to edit your php.ini file and replace it with the correct one.
  • Your PHP installation appears to be missing the MySQL extension which is required by WordPress, will appear when the PHP code on your site files is incompatible or not using the same version as the PHP of your site.
  • It could mean that the WordPress files are outdated and causing a conflict.
  • That the MySQL extension isn’t installed or enabled, or that the PHP extension is not configured properly.
  • Any one of these issues could be the cause for this error.

Your PHP installation appears to be missing the MySQL extension which is required by WordPress

Solving our message where your PHP installation appears to be missing My SQL extension which is required by WordPress so this error usually happens when you do a migration to a new hosting which is running the new version of PHP while your WordPress still running the old version of WordPress.

So to temporarily solve the issue you will need to log in to your new hosting cPanel and on your cPanel I’ll scroll down to the part where you see the PHP selector on the PHP selector you will need to roll back your PHP to the lowest version you can try to match the version with the version that you are previously hosted but if you can’t find that it can try the lowest version work on your way up.

Click update to set it Okay once you have done that go back through your website and do a refresh on the website as you can see here we have successfully recovered the website. Now, this is a temporary solution. To permanently solve this issue we need to update our WordPress this is to make sure there are the latest WordPress will support the latest PHP that we are hosted on Okay now we have successfully upgraded to the latest version of WordPress we go back to the cPanel to use the latest PHP version click on back, select the latest PHP version and click update.

Once we have done that we go back to our website and we try to refresh our website to see if this is supported okay it seems that we are hitting issues even if the latest version of WordPress and the latest version of PHP so we need to drill down further to solve the error.

A good place to look for is you need to look if there are any PHP dot ini on your root website footer or you need to check your .htaccess for any customized code so from here onwards there are no one-size-fits-all solutions and issue it depends very much on what you are facing and you need to troubleshoot accordingly you may also revert back to the previous PHP version but I would definitely recommend upgrading PHP as there will, there may be compatibility issues in the future so to start the troubleshooting or we go back to the cPanel, next click on file manager next I’ll do a reload to make sure I’m getting the latest file from the hosting site so the best way to troubleshoot this is to a debug or checking the error log.

Now there are some PHP warnings over the log but I’m pretty shouldn’t cause the WordPress to fail so the best way to troubleshoot this is to look for the .htaccess file or any PHP dot ini file at the root folder of your website I really am proceeded by editing the .htaccess file, So you can see that the default is there but there are some additional PHP line so this may be the line that is causing the issue on backing up this code just in case I do is safe I’ll go back to the website and do a refresh it seems that I have solved the issue the additional line at the .htaccess is the one causing the PHP issue next I will go back to my cPanel to set the version to the latest PHP version so confirm that everything is working so it seems to be working well.