Web applications like WordPress, Joomla and custom scripts store their content in a database. If you’re installing something manually, you’ll need to create a MySQL database and a user for it. Here’s the process, which is simpler than it sounds.
The three pieces you need
A working database setup has three parts: the database itself, a user that connects to it, and the privileges linking that user to the database. Your application needs all three, plus the password, to connect. Miss the privileges step and the app can’t talk to the database even with the right name and password.
Step 1: Create the database
- In cPanel, open MySQL Databases under the Databases section.
- Under Create New Database, type a name and click Create Database.
Note that cPanel prefixes the name with your account username, so a database you call shop becomes something like user_shop. Use that full name when configuring your app.
Step 2: Create a user
- Scroll to MySQL Users → Add New User.
- Enter a username and a strong password (use the generator).
- Click Create User.
Like the database, the username gets your account prefix. Save the password somewhere safe — you’ll need it to configure the application.
Step 3: Link the user to the database
- Scroll to Add User to Database.
- Select your new user and your new database from the dropdowns, then click Add.
- On the privileges screen, tick ALL PRIVILEGES and save.
This is the step people forget. Without privileges, the user exists but can’t do anything with the database.
Configuring your application
When your app asks for database details, provide: the full database name (with prefix), the full username (with prefix), the password you set, and localhost as the host. On cPanel hosting the host is nearly always localhost.
A note on security
Give each application its own database and user rather than sharing one across several apps. That way, if one app is compromised, the damage is contained to its own database. Strong, unique passwords for each database user matter too.
That’s the whole process. If you’re installing WordPress, Softaculous handles all of this for you automatically — this manual approach is mainly for other applications or custom projects. Need a hand? Just ask.