How to change the database password for WordPress sites

WordPress makes use of a database for much of its functionality. This database lives on a specialised database server, separate from the web server that hosts your WordPress website.

If the database password is reset for security reasons, then the WordPress configuration.php file included with your web files also needs to be updated accordingly, or else the website will break.

1. Change your database passwords via konsoleH

In this step, you will change your database password on the database server.

Note: Subdomains and Multiple Domains make use of databases from the main account, so you need to log in to the main account domain.

  1. Browse to konsoleH and log in at Admin or Domain level
  2. Admin level: Select or search for the applicable domain
  3. Select Manage Services in the left-hand menu
  4. Select Databases > Manage MySQL
  5. Select the applicable database and click Reset Passwords
  6. Manage MySQL 
    • The Full Password is the most important. It allows access to the entire database and allows you to create or delete any database information, columns or rows. The other passwords can be ignored.
  7. Enter your new database password(s), which can be your own choice or click Generate Password to use an auto generated, secure password.
  8. Important: Record your new password(s) in your own secure location before clicking Apply Changes (top right)

2. Edit connection strings via File Manager:

In this step, you will update the password on your account on the webserver.

  1. Click Manage Services from the left-hand menu
  2. Select Files & Folders > File Manager
  3. Select the configuration.php file and click on it
    • Note: If the domain is a subdomain or Multiple Domain, you will need to access the File Manager of the main account and then find the relevant domain’s files within the public_html folder.
  4. Select Edit from the right hand menu
  5. Search for the information you wish to change, click in the text and replace, where
    • DB_NAME is the database name
    • DB_USER is the database login
    • DB_PASSWORD is the database password
    • DB_HOST is the database server name (note that the database does not live on the same server as the website)
  6. Click Save Changes