The vast majority of settings and features can be handled within the WordPress administation section. However, when troubleshooting or under extreme circumstances, you may need to work directly with the database. Most hosting accounts contain more than one database, so you will need to know exactly which database to work with. This article will demonstrate how to locate the database name your particular WordPress installation is working with.

How to locate your WordPress installation's database name

  1. First, you will need to log into your cPanel account.
  2. Next, you will need to open and enter the File Manager tool.
  3. From the File Manager, you will need to locate and move to the root folder for your WordPress installation. If you are using your main domain, the root folder will be public_html. If you are using a domain name, then it will be under public_html/domainname (For example, if example.com is an addon domain, you will need to fin the public_html/example.com folder)
  4. Once in the root folder for your application, you will see many files. The find the wp-config.php file. Highlight the file and then click on the Edit button found in the toolbar across the top of the screen. A popup will appear on the screen, click the Edit button there as well.
  5. Once in the editor, you will see a lot of code regarding WordPress. Just past the code comments, around line 19, you will see the code for the database name. It appears like the example below:
    define('DB_NAME', 'userna5_wp123');
    The database name parameter is actually composed of two parts. In our example userna5_wp123, the first part is the cpanel username (userna5), and the second part is the actual database name (_wp123)
  6. Write down your database name in a secure location so you can remember it when you need to access it using the phpMyAdmin tool.
Did you find this article helpful?

We value your feedback!

Why was this article not helpful? (Check all that apply)
The article is too difficult or too technical to follow.
There is a step or detail missing from the instructions.
The information is incorrect or out-of-date.
It does not resolve the question/problem I have.
How did you find this article?
Please tell us how we can improve our Support Center:
Email Address
Optional, but our team may contact you for more information.
Like this Article?

Post a Comment

Name:
Email Address:
Comment:
Are you a bot?
Submit

Please note: Your name and comment will be displayed, but we will not show your email address.

Write New!
Do you want to publish a tutorial to our support center?

News / Announcements

SSL Certficate Warnings
Updated 2014-04-14 11:34 am EST
Hits: 1958
Heartbleed 0-day OpenSSL security bug
Updated 2014-04-14 04:43 pm EST
Hits: 5197

Related Questions

Here are a few questions related to this article that our customers have asked:
Ooops! It looks like there are no questions about this page.
Would you like to ask a question about this page? If so, click the button below!
Ask a Question

Need more Help?

Search

Ask the Community!

Get help with your questions from our community of like-minded hosting users and InMotion Hosting Staff.

Current Customers

Chat: Click to Chat Now E-mail: support@InMotionHosting.com
Call: 888-321-HOST (4678) Ticket: Submit a Support Ticket

Not a Customer?

Get web hosting from a company that is here to help. Sign up today!