Setting up MariaDB on Windows is quick and easy. This guide walks you through the steps to download the installer, configure MariaDB and manage it with a graphical tool like HeidiSQL.

Why use MariaDB on Windows?

Windows is widely used in many busi­ness­es and de­vel­op­ment en­vi­ron­ments. MariaDB runs reliably on Windows, providing the same func­tion­al­i­ty as it does on Linux. If you need to run web ap­pli­ca­tions locally or want a familiar de­vel­op­ment en­vi­ron­ment, in­te­grat­ing MariaDB on Windows is a simple solution.

What are the re­quire­ments for running MariaDB on Windows?

  • Windows 10 or 11 (64-bit rec­om­mend­ed)
  • Ad­min­is­tra­tor rights for the in­stal­la­tion
  • Internet access to download the installer
  • Optional: HeidiSQL (rec­om­mend­ed for graphical man­age­ment)
Managed Databases
Time-saving database services
  • En­ter­prise-grade ar­chi­tec­ture managed by experts
  • Flexible solutions tailored to your re­quire­ments
  • Leading security in ISO-certified data centers

How to install MariaDB on Windows step by step

The in­stal­la­tion process is straight­for­ward, with an official installer that guides you through each step. This tutorial covers the entire process.

Step 1: Download the installer

  1. Go to the download section of the MariaDB website.

  2. On the page, select MariaDB Community Server and then click the Windows (MSI Installer) option.

  3. Download the current version, such as MariaDB 11.7 for Windows x64. Be sure to select the correct ar­chi­tec­ture for your system.

Step 2: In­stal­la­tion with the MSI package

  1. Launch the down­loaded MSI installer by double-clicking on it.

  2. On the welcome screen, click Next to begin the setup.

  3. Accept the license terms by checking I accept the terms, then click Next.

  4. In the Custom Setup section, choose the com­po­nents you want to include. For a simple test en­vi­ron­ment, you can deselect third-party tools es­pe­cial­ly if you plan to install HeidiSQL manually.

  5. Select the in­stal­la­tion directory. The default is C:\Program Files\MariaDB x.x. You can change this if you prefer a different location.

Step 3: Server con­fig­u­ra­tion

  1. Set a secure root password for your MariaDB server. You’ll need this to log in as an ad­min­is­tra­tor later.

  2. Enable the Use utf8mb4 as default server’s character set option to ensure the database supports modern character sets.

  3. Leave other settings such as the port (3306), Windows service startup and use of the InnoDB engine at their default values, unless you have specific re­quire­ments.

  4. Click Install to begin the in­stal­la­tion. This will take about one to three minutes depending on your system.

Step 4: Test MariaDB Windows in­stal­la­tion

  1. After in­stal­la­tion, open the Windows Command Prompt (cmd).

  2. Run the following command to connect to your MariaDB instance:

"C:\Program Files\MariaDB 11.7\bin\mariadb.exe" -u root -p
cmd
  1. Enter the root password you set earlier. After suc­cess­ful­ly logging in, the MariaDB console will open and you can run SQL commands.

Step 5: Install HeidiSQL

  1. Go to the HeidiSQL website.

  2. Download the latest setup and install it as usual.

  3. When you first open HeidiSQL, the con­nec­tion manager will appear. Click New to create a new con­nec­tion.

  4. Enter the following con­nec­tion details:

  • Con­nec­tion Name: for example, “Local MariaDB”
  • Con­nec­tion Type: MariaDB or MySQL (TCP/IP)
  • Library: lib­mari­adb.dll
  • Hostname/IP: 127.0.0.1
  • Username: root
  • Password: the root password set in step 3
  • Port: 3306
  1. Click Save to save the con­nec­tion, then click Open to connect. You should now have access to your database instance.

Step 6: Create database

  1. Open HeidiSQL and connect to your MariaDB server.

  2. Right-click on your con­nec­tion in the nav­i­ga­tion pane on the left and select Create New -> Database.

  3. Enter a name for your new database, for example, __testdb__, and click OK. The new database will appear in the list and is ready for use.

Step 7: Restore backup

  1. Select the database from the left panel where you want to import a backup.

  2. Open the File menu -> Run SQL file.

  3. In the file selection dialog, choose your desired .sql file and click Open.

  4. HeidiSQL will run the SQL commands from the file. After a few moments, your database structure and data will be imported.

Compute Engine
The ideal IaaS for your workload
  • Cost-effective vCPUs and powerful dedicated cores
  • Flex­i­bil­i­ty with no minimum contract
  • 24/7 expert support included

Step 8: Adjust con­fig­u­ra­tion file

  1. Go to the MariaDB in­stal­la­tion directory in Windows, e.g., C:\Program Files\MariaDB 11.7\data.

  2. Open the my.ini file with a text editor of your choice. Be sure to run the editor with ad­min­is­tra­tive priv­i­leges.

  3. Make any necessary ad­just­ments. For example, you can change the character set and the maximum number of si­mul­ta­ne­ous con­nec­tions:

[server]
character-set-server=utf8mb4
collation-server=utf8mb4_unicode_ci
max_connections=200
ini
  1. Save the file and restart the MariaDB service to apply the changes:
net stop mariadb
net start mariadb
cmd

Your MariaDB en­vi­ron­ment on Windows is now fully set up and ready to use.

Go to Main Menu