Managed WordPress Hosting built different 💪

pressypress
Fixing problems

Fixing "error establishing a database connection"

WordPress is running but cannot reach its database. Your content is almost certainly still there.

1. Restart the container

  1. On your Pressy's overview, press Restart.
  2. Wait about thirty seconds and reload.

This fixes the common case, where the database process stopped or ran out of connections. Try it before anything else.

2. Check whether the database is still there

  1. Open Databases in your Pressy's sidebar.
  2. Your WordPress database is the first row, and it cannot be deleted from here.

If the list is empty or that row is gone, stop and write to us — do not create a new one, because a backup restore will bring back both the database and the files that match it.

3. Check the credentials WordPress is using

If the restart did not help and the database is listed:

  1. Open public_html/wp-config.php in the Files screen (edit a file).
  2. Find DB_NAME, DB_USER and DB_HOST.
  3. Compare the name and user against the Databases screen.

They should match. If the user is right but the password is not, reset it on the Databases screen with Reset password — the new password is shown once — then put that password into wp-config.php as DB_PASSWORD.

Change nothing else in that file. Keep a copy of the original before you edit it.

4. If it started right after a change

  • After editing wp-config.php — put your copy back.
  • After a plugin or theme updaterestore the most recent backup.
  • After a staging push — the push replaced live wholesale, and the backup taken automatically just before it is in your Backups list.

When to write to us

Write to us if a restart did not fix it and the credentials match. Say whether the Databases screen still lists your database — that tells us in one line which of two very different problems this is.

Didn’t solve it?

Write to us with your Pressy’s address and what you were doing when it went wrong. Answered by the people who built it.

Last updated