HostGator MySQL

MySQL is a database. If you want to create a dynamic website then you will need to use the database. Since MySQL is a free database, it is advisable to use MySQL database in creating a website. MySQL is now owned by Oracle but it is still open source database. MySQL database offers higher performance, reliable and easy to use. Due to all these reasons, MySQL is offered in almost every hosting company account. In this article, I am going to show you how to manage MySQL at HostGator.

Access MySQL Databases

If you want to access MySQL database section at HostGator then follow these steps.

1) Login to your HostGator cPanel using your username and password.

2) Now you will find the MySQL Databases option under the Popular Links section. You will also find the same MySQL Databases option under Databases section. Click on it to access the database management interface.

On this MySQL page, you will find two different sections. One is for creating MySQL username and another is for creating MySQL database. You will also need hostname to access the MySQL database but I think HostGator uses localhost for creating all databases. So no hostname is needed.

Create MySQL Username

Before you create the MySQL database, you will need to create MySQL username. You can use single username for multiple database access also but that is risky. If by chance your username is hacked then you will lose the access of all databases which comes under that username. So it is advisable to use separate username for separate databases.

To create the mysql username, first go to MySQL database page as shown above. Then scroll down, you will see MySQL Users section.

Here you need to enter the username in Username field. Then enter the password and reenter the password. Finally, click on Create User button.

Your username will be created. Click on Go Back button to return to the MySQL database page.

Create MySQL Database

Now second step is to create the database. Visit the MySQL database page. Here the first section is to create MySQL database. Just give the database name and click on Create Database button.

That's it. Your database will be created.

Assign User to Database

Only creating database and user name is not enough to access the MySQL database. You will have to give permission to the User for accessing database. You can do so by adding user to the database.

Go to MySQL database page. Then go to Add User To Database section. There select the user for which you want to give the permission to the database also select the database. Click on Add button.

That's it. You have successfully created database and allowed the permission to the user.

Now you can use this username, password and database name on any dynamic website. You can also use this database on open source softwares like wordpress, drupal, joomla etc…

Now I think you know how to create and manage MySQL databases at HostGator.

Back to Hostgator Tutorials

Go to Home