Knowledge base

1000 FAQs, 500 tutorials and instructional videos. Here, there are only solutions!

Troubleshooting connection issues between WordPress and the database

Update 08/03/2026

This guide is intended for users who are making changes to a web hosting environment where WordPress is installed.

 

Introduction

  • Following a change to your web hosting plan (migration from the old v1 60 GB hosting plan to the current plans), you may need to update the connection between your MySQL/MariaDB database and your WordPress site (to avoid the "error establishing a database connection" error, for example) and re-establish the link between WordPress and the MySQL/MariaDB database.

 

Modify the important elements

Here is the information to update in the wp-config.php file so that your WordPress site works (generally, a prefix has simply been added to the existing database name and username):

  1. the name of the MySQL database (bddname before, abcd_bddname after, for example)
  2. the server hosting the MySQL database (mysql.domain.xyz before, abcd.myd.infomaniak.com after, for example)
  3. the username used to access the MySQL database (userbdd before, abcd_userbdd after, for example)

 

Modify the wp-config.php file of WordPress

To do this:

  1. Find and save your current MySQL data according to the list above.
  2. Create an FTP account.
  3. Connect via FTP.
  4. Edit the wp-config.php file, which is located in the root directory of your WordPress site.
  5. Find the relevant paragraph and update the 3 pieces of information (according to the list above).
  6. Save the file, and that's it! Your WordPress will now connect to the correct database.

Has this FAQ been helpful?