WordPress Droplet MySQL Username

Hello DO: I am attempting to connect to The internal MySQL DB I logged in as root and wordpress_mysql_pass=“<some long string>”

I have tried connecting with client DataGrip (JetBrains) using username of **wordpress **and **wordpress_mysql **feel the pwd must be correct because the WordPress droplet is fuctional. But connecting to MySQL is not with either of the usernames.

Is there Some other client tool I should try?

Mark Wardell

Submit an answer

This textbox defaults to using Markdown to format your answer.

You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!

Sign In or Sign Up to Answer

These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.

Hello, @markdwardell

Would you mind sharing if you’re getting any exact error messages when trying to access the database using the client you’ve mentioned?

Have you tried to access the database using alternative client or simply by using the MySQL client when you’re logged in with ssh on the droplet itself?

You can check this tutorial as well:

How to Connect to a MySQL Server Remotely with MySQL Workbench

Regards, Alex

Hi @markdwardell,

So, the first thing you can always check to learn your user’s password without changing it is your WordPress’s wp-config.php file. In there you can see the database credentials your website is using. Usually, it looks something like this:

/** The name of the database for WordPress */
define( 'DB_NAME', 'wordpress' );

/** MySQL database username */
define( 'DB_USER', 'wordpress' );

/** MySQL database password */
define( 'DB_PASSWORD', 'PasswordHere' );

/** MySQL hostname */
define( 'DB_HOST', 'localhost' );

/** Database Charset to use in creating database tables. */
define( 'DB_CHARSET', 'utf8' );

/** The Database Collate type. Don't change this if in doubt. */
define( 'DB_COLLATE', '' );

And when using a WordPress droplet, you can find the file at the following path - /var/www/html/wp-config.php

Now, if you actually changed the password of your wordpress user, you’ll need to update it in your configuration file as well.

If you want to change the password your wordpress user is using, you can do the following once you’ve SSHed to the droplet:


Once you do change the password, remember to change it in the wp-config.php file as well.

Regards, KFSys