Few days back I wrote a post about installing wordpress on your web space using FTP. In that post I did mention that after uploading all the files of WordPress on server we need to enter DB name, DB username, DB password other details in WP-config.php file which helps WP application to connect with database. So I am here to write about creating Database in Cpanel of your website.
Steps to create MySQL Database in Cpanel
Login to your Cpanel with the credentials you got from your webhost. The url address of cpanel is like yoursite.com/cpanel. Fill the username and password in the input fields and click on login.
You will be logged into your cpanel where you will see so many stuffs. Look for Mysql database as you can see in this screenshot.
Click on the icon “Mysql Database” and it will take you to a page where you can see the option for creating database. Look for “Create New Database” as shown in this screenshot:-
Note: Here I have blurred the prefix which is usually the cpanel’s account username. If you want to remove this prefix then you can do by the process mentioned here but I haven’t removed and that’s why it’s showing there. [For security reason I have blurred this]. For example, I am considering it to be XYZ
Type any name you want in the New Database field, Type Test and click on Create Database button. Clicking on it will take you to this page(see screenshot below) saying that the Database with name “XYZ_Test” is added.
Now you need to create a database user. Click on “Go back” and look for “Add New User” which looks like this:-
Type any name you want, say test1 in the username field and fill the password field as well and click on “Create user”.
Clicking on “Create user” will take you to this page(check Screenshot) saying that the user xyz_test1 with password *******, is added.
Now you have to add this user to the database you have just created. Now click on “Go back” and check for “Add user to Database” as shown in this screenshot:-
Now use the dropdown and select xyz_test1 in the user field and xyz_Test in database field and click on Add.
Clicking on Add will take you to this page:-
Check user privileges you want to give or click on check box “All Privileges” and click on Make Changes.
This will take you to this page confirming that user xyz_test1 was added to the database xyz_Test.
That’s it. You are done now!
Now you are having these details:-
Database name: xyz_Test
Database Username: xyz_test1
Now you can fill these details into wp-config.php.
P.S. I am learning to write better How to Guides. So I would like to request you all to give feedback. do let me know in comments where I am lacking so that I can improve and write better How to guides for you.