Knowledge base
Web Hosting
Creating a MySQL database
Last updated 8/1/2026 by Alfie Web Solutions
Most website software that stores data - WordPress, forums, e-commerce platforms - needs a MySQL database to run. Here's how to set one up in DirectAdmin.
Creating the database
- Log in to DirectAdmin.
- Click MySQL Management.
- Click Create new Database.
- Fill in:
- Database name - DirectAdmin automatically prefixes this with your username (e.g. if your username is "acme1", naming it "shop" creates acme1_shop). This prefix is normal and expected.
- Database username and password for the account that will access it - this can be the same name as the database or different.
- Click Create.
Make a note of the full database name, username, and password - most software setup wizards (like WordPress) will ask for these.
Where to use these details
When installing software that needs a database, you'll typically be asked for:
- Database host: localhost
- Database name: the full name including your prefix, e.g. acme1_shop
- Database username: the full username including your prefix
- Database password: the password you set
Browsing your database (phpMyAdmin)
To view or edit the actual data/tables in a database:
- Go back to MySQL Management.
- Click phpMyAdmin next to the database you want to open.
- You'll be logged in automatically, where you can browse tables, run queries, and export backups.
Adding an existing user to another database
If you need one login to access multiple databases:
- In MySQL Management, find the database.
- Click Modify (or the equivalent "add user" option).
- Select the existing user and grant it All Privileges.
- Save.
Submit a ticket under Web Hosting if a database-driven install fails and you're not sure whether the issue is your database details or something else - include any error message you see.
