Published on October 16, 2017 by WPBeginner

Having an error appear on your WordPress site can certainly be terrifying if you don’t know what caused it or how to fix it. The most dangerous sounding one can be the error establishing database connection which does not even let you log in to your site. In this video, we will show you how to fix the error establishing a database connection in WordPress.

Text version of this tutorial
www.wpbeginner.com/wp-tutorials/how-to-fix-the-error-establishing-a-database-connection-in-wordpress/

If you liked this video, then please Like and consider subscribing to our channel for more WordPress videos.

Check us out on Facebook
www.facebook.com/wpbeginner

Follow us on Twitter
twitter.com/wpbeginner

Checkout our website for more WordPress Tutorials
www.wpbeginner.com

In this tutorial we will be recommending the use of FTP, for how to use FTP and what it is you would want to take a look at our article:

www.wpbeginner.com/beginners-guide/how-to-use-ftp-to-upload-files-to-wordpress-for-beginners/

If you wanted to download notepad++ that we used in this video you can find it here:

notepad-plus-plus.org/

The solutions we go through are:

– Editing the wp-config.php to pull up the repair prompt
– Checking the wp-congig.php that the connection options are correct
– Editing your MySQL with your host to attempt to fix the error

Leave a Reply

4 Comments on "How to Fix the Error Establishing a Database Connection in WordPress"

Notify of
avatar

Em An
Guest
Em An
23 days 19 hours ago

شكراتم الحل

Nicholas Holloway
Guest
Nicholas Holloway
1 month 3 days ago

Thanks! great content

Kraphik ThreeDee
Guest
Kraphik ThreeDee
1 month 28 days ago

Thanks this worked for me. I only re-entered password again in mysql database and then repair database option in wordpress.

Kraphik ThreeDee
Guest
Kraphik ThreeDee
1 month 28 days ago

Thanks this worked for me. I only re-entered password again in mysql database and then repair database option in wordpress.

wpDiscuz