Development and databases

Manage MySQL databases, users and permissions in cPanel

Reviewed on 3 min read mysql bases de datos

In cPanel > Manage My Databases (formerly MySQL Databases) you can create databases, manage users and assign their permissions. To view or change the tables, use phpMyAdmin.

Create a database and its user

  1. In Create New Database, enter a name and save. Note down the full name, including the account prefix.
  2. In Add New User, create a dedicated identity for the application and a unique password.
  3. In Add User To Database, select both and assign the privileges the application needs on that database.
  4. Enter those details in the website's configuration and test the connection.

Creating a user does not automatically give it access to every database. To complete the process in a guided sequence, use the Database Wizard.

Review existing databases and users

The list shows the databases created, their size and the associated users. Identify which application uses each one before changing it: in WordPress you can check DB_NAME and DB_USER in wp-config.php.

One installation may need all privileges on its database to create or update tables; another integration may need read-only access. Use a separate user and limited permissions for an external query or a temporary job.

The size shown may update with a delay. Do not delete tables or databases just because you do not recognise their name: there may be several applications or old installations still in use.

Change a password or a name

Changing a MySQL user's password affects every application that uses it. Prepare the new configuration and coordinate the update to reduce the time without a connection. The MySQL password is separate from the client area and cPanel passwords.

Renaming a database involves moving data and recreating permissions. It can interrupt connections and requires updating the name in the applications. Keep a recoverable copy and plan the change, especially if the database is large. If you only need a test copy, clone the database under another name.

Check or repair a database

The Modify Databases section offers check and repair functions. It is not a general optimiser or a fix for any connection error. First identify the message and keep a copy.

The repair available depends on the engine. REPAIR TABLE does not repair InnoDB tables the way it does MyISAM ones; if the problem affects InnoDB, ask support or prepare a verified restore. Avoid repeating repairs without understanding the result.

Remove access or databases

Removing a user's assignment removes its permissions on that database; deleting the user can affect all its assignments. Deleting the database removes its data. They are different operations.

Before deleting, confirm that no website, scheduled task or integration uses it and that you have the copy you need. Afterwards, check that the applications that must stay active still work.

You may also find useful

Something wrong or out of date? Tell us and we will review it.