Hosting Question? Find the Solution -

KNOWNHOST KNOWLEDGE BASE

Browse our Guides, Articles, and How-To's

How to create MySQL Database and User in cPanel?

Category: cPanel
Tags: # # # # # # # #

Creating a MySQL database, User, and assigning that User to the Database through a command-line interface may get tricky for newbies who don’t know of it. Through cPanel, this job gets easier. All you have to do is perform some informed clicks and VOILA! You’re good to go!


How to create a MySQL Database?

1. Log in to cPanel using Username Password. i.e; (https://yourdomain.com:2083 or https://yourdomain.com/cpanel)

2. Navigate to Databases → MySQL® Databases.

3. Enter the name of Database → Click on “Create Database“.


How to create a MySQL User?

1. Log in to cPanel using Username Password. i.e; (https://yourdomain.com:2083 or https://yourdomain.com/cpanel)

2. Navigate to Databases → MySQL® Databases.

3. Navigate to MySQL Users and enter the required information.

Username: Type username for the database user.

Password: Enter the complex password, or you can take a help password generator to that job for you.

Password (Again): Re-confirm the password by entering it again in this file.

4. To save all the configurations and create a new database user, Click on “Create User“.


How to assign a User to a MySQL Database?

1. Log in to cPanel using Username Password. i.e; (https://yourdomain.com:2083 or https://yourdomain.com/cpanel)

2. Navigate to Databases → MySQL® Databases.

3. Navigate to Add User To DatabaseSelect Database & User → Click on Add.

4. Select the required permissions/privileges → Click on Make Changes.

5. You can see confirmation: Success: You saved “khdemoco_test”’s privileges on the database “khdemoco_dbname”.


How to delete MySQL Database?

1. Log in to cPanel using Username Password. i.e; (https://yourdomain.com:2083 or https://yourdomain.com/cpanel)

2. Navigate to Databases → MySQL® Databases.

3. Navigate to the “Current Databases“.

4. Locate the Database Name which you want to delete → Click on “Delete“.


How to delete MySQL User?

1. Log in to cPanel using Username Password. i.e; (https://yourdomain.com:2083 or https://yourdomain.com/cpanel)

2. Navigate to Databases → MySQL® Databases.

3. Navigate to Current Users.

4. Locate the MySQL User → Click on “Delete“.


Conclusion

Now that we’ve gone over how to create MySQL database, MySQL user, delete MySQL database, delete MySQL user with the assignment of privileges to MySQL user with step by step instructions. Now you can perform any operation/action described in this article.

KnownHost offers 365 days a year, 24 hours a day, all 7 days of the week best in class technical support. A dedicated team is ready to help you with requests such as creating MySQL databases and users, should you need our assistance. You’re not using KnownHost for the best web hosting experience? Well, why not? Check with our Sales team to see what can KnownHost do for you in improving your web hosting experience.