[Solved]: Changed password for MySQL database and can not connect Magento now? (Error: SQLSTATE[HY000] [1045])

Did you just update the password for your user access on MySQL database and receiving an error message when trying to connect to Magento:

Error: SQLSTATE[HY000] [1045] Access denied for user ‘xxx’@’localhost’ (using password: YES).

It’s an easy two step process to resolve this issue, start with configuration of your database credentials for magento in file name: local.xml in location: app/etc/local.xml


Edit the credentials in above mentioned section of the file and Save it.

Step two, clear your Magento cache. Magento automatically caches its configuration files so it doesn’t have to load them from disk on every request. In a typical setup, you can clear the cache by removing all files/folders in the following directory var/cache/…

However, if your system has customized or third party applications integrated in it, it is important to flush other cache systems manually as well.