If you manually installed WordPress into your hosting account and are getting an “Error establishing a database connection” message when trying to connect to WordPress, you need to modify your wp-config.php file to work with our Database servers.

/** The name of the database for WordPress */
define(‘DB_NAME’, ‘putyourdbnamehere’);
/** MySQL database username */
define(‘DB_USER’, ‘usernamehere’);
/** MySQL database password */
define(‘DB_PASSWORD’, ‘yourpasswordhere’);
/** MySQL hostname */
define(‘DB_HOST’, ‘localhost’);


Enter the Database information from your Database as follows:

  • putyourdbnamehere is your MySQL Database Name
  • usernamehere is your MySQL User Name
  • yourpasswordhere is your MySQL password
  • localhost is your MySQL Host Name

And now check your wordpress site. It must be working. 🙂

One thought on ““Error establishing a database connection” : WordPress Error Resolved”

Leave a Reply