You have created a website under WordPress or you are in the process of creating your website and you encounter the following error :
Fatal error: Uncaught Error: Class 'WP_HTTP_Response' not found
This error is blocking and prevents you from advancing in the realization of your website.
WP_HTTP_Response is a “Core Class“, a base class of WordPress if you prefer. It allows you to prepare HTTP responses.
If you have just installed WordPress and this error appears, it is simply because there was a problem with your WordPress installation.
If it appears one day on your site while it has been in place for a long time, it may be caused by an update that could not be completed or a hacking of your site.
There are not many solutions to solve this problem. If you are lucky enough to have access to your WordPress administration, you can try reinstalling WordPress: in your dashboard, look for the “Updates” menu. Once there, click on “Reinstall Now“. This will allow you to keep your content, themes and plugins.
If you do not have access to the administration, you can connect via FTP to reinstall WordPress :
- Reinstall WordPress completely, keeping nothing: for example if you have just installed WordPress, and the error mentioned in this article occurs, you can not bother and simply reinstall WordPress. If necessary, clean up your database by deleting the tables from your previous installation, re-drop the WordPress files and restart the installation.
- If you are not comfortable with this installation process, some hosting providers offer “one-click” installation solutions allowing you to access a pre-installed WordPress
- Remember to check the archive or source you used to retrieve WordPress. You need to acquire it from a safe, trusted, known, and recognized source : Download WordPress. Next, check that the ZIP file you downloaded is complete and includes*
- Reinstalling WordPress, without overwriting your changes: it will be the same operation as before, drop your WordPress installation on your server, but excluding the /wp-content folder.
In the case of a complete reinstallation of WordPress without data retention (neither plugin nor theme), you can clean up your previous installation by deleting the files from your old WordPress and emptying your database.
Finally, as is often the case, it will be necessary to check the conformity and integrity of your installation once these operations have been carried out. Reminder: if this problem occurred while your website was already in place, it is strongly recommended that you investigate the cause of your problem. If it is a hacking, an audit of your website, with research of the cause and correction of the flaw will prove to be essential so that the problem, or even more serious, does not occur or appears again.