Skip to main content

How to Create a MySQL or MariaDB Database and User in Windows Control Panel

You can create a new MySQL or MariaDB database and a corresponding database user within the Windows Control Panel (WCP). This process allows you to set up the necessary infrastructure for your applications to connect to and manage data.

You can create a new MySQL or MariaDB database and a corresponding database user within the Windows Control Panel (WCP). This process allows you to set up the necessary infrastructure for your applications to connect to and manage data.

Before you begin

You will need:

  • An active Hostek account with access to the Windows Control Panel (WCP).

  • The specific database name you wish to create.

  • A unique username and a secure password for the database user.

  • Knowledge of the specific database (MySQL or MariaDB) your application requires.

Create a MySQL or MariaDB Database

  1. Log in to the Windows Control Panel.

  2. Navigate to Databases > MySQL & MariaDB.

  3. Select the database engine you are using (MySQL or MariaDB).

  4. Click on MySQL & MariaDB Databases (or the equivalent link for your specific engine).

  5. Click Create Database.

  6. Enter the desired name for the database.

  7. Select the character set and collation (typically utf8mb4_unicode_ci for modern applications).

  8. Click Create.

Create a Database User

  1. In the Windows Control Panel, navigate to Databases > MySQL & MariaDB.

  2. Select your database engine and click on MySQL & MariaDB Users.

  3. Click Create User.

  4. Enter a unique username (e.g., app_user).

  5. Enter a strong password for the user.

  6. Select the host from which the user can connect. For most standard applications, select Localhost or Any Host (if the application is hosted on a different server).

  7. Click Create.

Assign Permissions to the User

  1. In the MySQL & MariaDB Users section, locate the user you just created.

  2. Select the user and click Manage Permissions.

  3. Select the specific database you created in the previous step.

  4. Select the privileges you wish to grant the user (typically All Privileges for a primary application user).

  5. Click Save or Update.

Confirm the result

  • The new database will appear in the list of available databases in the Windows Control Panel.

  • The new user will appear in the user management list.

  • You can verify the connection by attempting to log in to the database using the new credentials via a management tool like phpMyAdmin or a local database client.

Limitations

This procedure creates the database and user at the server level. It does not automatically configure your application's connection strings; you must manually update your application's configuration files with the new database name, username, and password.

Did this answer your question?