Help! I cannot connect to my database!

A commonly occurring issue is that people are unable to connect to the databases they created. Here is a short checklist

Make sure you are using your hosting account password.

The most common issue is that people are not using the right database password. You should use the hosting account password in your script configuration. Important: the hosting account password is not your client area password.The hosting account password is randomly generated when you create an account, and you can find or change it in your client area (click the account in the accounts list).

Make sure you are using the right database hostname (not localhost).

Most hosting providers use localhost for the database hostname. This does not work for InfinityFree. In most cases, the database hostname looks like sql123.epizy.com. You can find your database hostname in your control panel in the MySQL Databases section.

Make sure you are using the right database name and username.

Your database name and database username can be found in the MySQL Databases in the Control Panel of your hosting account. The database username typically looks like epiz_12345678 and the database name looks like epiz_12345678_mydb.

I’m sure I’m using the right database credentials.

If you’re completely sure you are using the right database password, database hostname, database name and database username, but you are still unable to connect to your database, you can get help by opening a new forum discussion. When doing so, please don’t forget to include the full error message returned by the database connection code.

1 Like