No announcement yet.

Reset WordPress Database Password?

  • Filter
  • Time
  • Show
Clear All
new posts

  • Reset WordPress Database Password?

    How to Change the WordPress Database Password?

    Can you please guide me step by step procedure to change/reset the WordPress Database Password?
    Lalitkumar Waghulkar | Business Development Executive.
    T: +91-253-2313625 | M: +91-8888889939 | Skype: lalit_403

  • #2
    You can change/reset the WordPress database password from your hosting control panel. Since Cpanel is the most popular web hosting control panel, this guide is based on Cpanel.

    Change/Reset Database Password:

    1. Login to your Cpanel and go to "MySQL Databases" under Databases option, here you will see MySQL database and its user for your WordPress website.

    2. Next scroll down to "Current User" section and Click on "Change Password" for the user that is being used by your WordPress website to access the database.

    3. Enter a new password in the first box (strong password is recommended), confirm the password in the second box and click on "Change Password".

    This way you have changed your WordPress database password, but this will cause your website to display an "Error establishing a database connection" unless you update the new database user password in the WordPress configuration file.

    Update the WordPress Configuration File (wp-config.php):

    1. Go to the "Cpanel >> File Manager" option and locate the WordPress installation path then right-click on the "wp-config.php" file and select "Edit"

    2. In the wp-config.php file, find the following entry.:
    /** MySQL database username */
    define( 'DB_USER', 'old_password' );
    3. Replace "old_password" inside the quotation marks with the new database password that you have chosen earlier and then save the file.

    Succeed! You have changed your WordPress database password and also updated your WordPress configuration file.