Hello InfinityFree Support, Both of my websites are experiencing MySQL connection error 1045. **We

Website URL

https://abdullahi-portfolio.great-site.net/

Error Message

Website temporarily unavailable.

Database error code: 1045 – MySQL Access Denied.

Database connection test result: TEST B: Error 1045.

Other Information

I have already performed the following troubleshooting steps:

  • Verified the MySQL hostname, username, database names, and port.
  • Updated the MySQL password in both website configuration files.
  • Confirmed that both databases exist in phpMyAdmin.
  • Tested the MySQL connection without selecting a database, but error 1045 persists.
  • Confirmed that both website versions are affected.

The InfinityFree dashboard also displays a warning that the Control Panel is unreachable.

Could you please investigate whether this issue is related to MySQL authentication, password synchronization, or a server-side problem?

Thank you for your assistance.

Welcome to the InfinityFree community forum! Good to have you here.

  • Most people answering here are volunteers. They’re often the fastest source of help. Admin (the only staff member) checks in about once a day for issues on our end.
  • Volunteers can’t see your account or website. Share what you actually see, like error messages and what happens when you try something. That’s more useful than your theory of what’s wrong.
  • AI tools often get InfinityFree wrong. If a volunteer’s advice differs from what an AI told you, please try the volunteer’s suggestion first.
  • Solving an issue is a joint effort. Try the suggestions you get and report back what happened.

Beep boop, I’m a bot! I dug through the forum to get you started. I sometimes get things wrong though, so do with this what you will until a human has a look.

Error 1045 means MySQL rejected the login, which usually comes down to the wrong password. Common MySQL Connection Errors says the database password is your hosting account password, not your members area password. You can find it in the members area: open the account, scroll to MySQL Details and click Show next to Password.

So which password did you paste into both config files? Since you updated it, it’s worth checking that it’s the one shown under MySQL Details for the account. Also check the username in the config. It should be the account username, not the database name.

The MySQL host for the hosting account behind abdullahi-portfolio.great-site.net is sql311.infinityfree.com. Is that what both configs use, and not localhost?

Only one hosting account on your profile has a website. If your second website is on a different account, tell me which MySQL host and username its config uses.

The control panel warning does match an open status incident about the control panel being unreachable. That incident only covers the control panel, though, and doesn’t mention MySQL login errors.

Thank you for your response.

I can confirm the following:

  • Both website versions are hosted under the same hosting account: if0_43066027.

  • Both use the MySQL hostname sql311.infinityfree.com.

  • Both use the MySQL username if0_43066027.

  • I copied the password directly from MySQL Connection Details in the InfinityFree dashboard and updated both configuration files.

The databases are:

  • if0_43066027_abdullahi_portfolio

  • if0_43066027_awm

Despite these checks, both websites still fail to connect. Testing without selecting a database also returns error 1045.

Could a staff member please investigate the MySQL authentication issue?

Thank you.

If you admin to do it, wait

Thanks for confirming all of that so clearly — the fact that both sites fail, with the right host, username and a password copied from the dashboard, and that even connecting without selecting a database gives the same 1045, is useful. It rules out a wrong database name or a mistake in one site’s config, so the problem looks like it is on the account/authentication side rather than in your code.

One test that can help narrow it down while you wait for Admin: try logging in to phpMyAdmin from the client area with the same username and password. If phpMyAdmin also rejects them with 1045, that points to the credentials not being accepted for the account. If phpMyAdmin works, the issue is more likely in how the password is stored or read in the config files — in that case, check for an extra space or hidden character when pasting, and make sure the password used is the hosting account password, not the client area one.

If you changed the password recently, it is also worth waiting a little before trying again, as the change can take a while to sync. I would not keep resetting it repeatedly, since each reset can restart that process.

I checked your code and I spotted a very clear issue. Because in your database.php script, the database password is configured like so:

$password = <<<'AWM_PASSWORD'
REPLACE_WITH_NEW_MYSQL_PASSWORD
AWM_PASSWORD;

As you can probably tell: that’s not actually the right password to use.