How To Install MariaDB on Windows
Enjoying this content? Subscribe to the Channel!
Lightning-Fast MariaDB Installation on Windows: Setup as a Service (Step-by-Step Tutorial)
Welcome back to Darren’s Tech Tutorials!
If you’re ready to power up your database projects with a robust, open-source solution, MariaDB is the place to start. A fantastic replacement for MySQL, MariaDB is powerful, reliable, and incredibly fast.
In this comprehensive guide, we’re going to walk through the entire process of installing MariaDB on your Windows machine (Windows 10 or 11). Crucially, we’ll ensure it’s configured correctly to run automatically as a Windows Service, providing maximum stability and ease of use.
Ready to dive in? Let’s get that server running!
Step 1: Downloading the MariaDB Installer
The very first step is securing the official installation file. We always recommend getting the installer directly from the source.
Action Steps:
- Navigate to the Official Site: Open your web browser and go to the official MariaDB download page.
- Select the Right Version: Look for the latest stable release tailored for Windows (usually listed as “Windows MSI Package”). Ensure you select the correct architecture (typically 64-bit).
- Download: Click the download link. This will save the
.msiinstallation file to your computer.
Once the download is complete, locate the installer file—it’s time to run the setup wizard!
Step 2: Running the Installation Wizard
The installation wizard streamlines the setup process, but we need to pay close attention during the configuration stages to ensure the service is set up correctly.
Installation Steps:
- Launch the Installer: Double-click the downloaded
.msifile. If prompted by User Account Control (UAC), click Yes. - Welcome Screen: Click Next to bypass the welcome screen.
- License Agreement: Read and accept the terms of the license agreement, then click Next.
- Custom Setup (Optional): We recommend choosing Custom if you want to verify the installation path, but for most users, the default settings are perfectly fine. If you use the default, simply click Next.
- Plugins (Optional): You can usually leave the default plugins selected unless you have specific compatibility requirements. Click Next.
Step 3: Configuring the MariaDB Server
This is the most critical stage. Here, we define the security credentials and ensure MariaDB starts automatically when your PC boots up.
Configuration Essentials:
-
Set the Root Password: You must set a strong password for the database administrator account (
root).- Enter your desired password in the New root password field.
- Re-enter the password in the confirmation field.
- Pro Tip: Write this password down immediately! Without it, you cannot administer your database.
-
Enable Remote Access (If Needed): If you plan to access this database from another computer on your network, check the box labeled Enable access from remote machines for ‘root’. (If this is strictly a local development server, you can leave this unchecked for higher security.)
-
Configure the Server Service: This is where we install MariaDB as a persistent Windows Service.
- Ensure the checkbox labeled Install as a service is selected. This allows MariaDB to start automatically without manual intervention.
- You can leave the default Service Name (usually
MariaDB). - The TCP Port should remain at the default value of
3306, which is the standard port for MySQL/MariaDB. - Click Next once configurations are complete.
-
Final Options: On the final configuration screen, unless you require specific advanced settings related to the storage engine or buffer size, you can usually click Next one last time.
-
Ready to Install: Click the Install button to begin copying files. The process is usually very quick!
-
Finish: Once the installation completes, click Finish. Congratulations, MariaDB is now installed and running as a service!
Step 4: Testing Your MariaDB Installation
We’ve installed the server, but how do we know it’s actually working and listening for connections? We can quickly test it using the MariaDB command-line client.
Verification Steps:
-
Open Command Prompt (or PowerShell): Search for
cmdin the Windows Start Menu and open it. -
Navigate to the Client Directory: MariaDB adds itself to the Windows PATH variable, so you can usually run the client directly.
-
Log in as Root: Execute the following command, which calls the MariaDB client and attempts to log in using the
rootuser:mysql -u root -p -
Enter Password: The command prompt will ask you to enter the password you set up in Step 3. Type your root password and press Enter.
If successful, you will see the MariaDB welcome prompt, meaning you are logged into your new server!
Welcome to the MariaDB monitor. Commands end with ; or \g.
MariaDB [(none)]>
You can now confirm the status by running a simple query:
SHOW DATABASES;
If you see a list of default databases (like information_schema, mysql, and performance_schema), your installation is fully functional! You can exit the prompt by typing exit;.
Wrap-Up and Next Steps!
You did it! You now have a high-performance MariaDB server running stably on your Windows machine, configured to automatically start as a service every time you boot up. This foundation is perfect for development, testing, or production environments.
What’s next? Now that your server is running, you can connect to it using popular tools like DBeaver or HeidiSQL, or start developing applications that leverage its power!
If you found this guide helpful, please like the video this post came from, and subscribe to Darren’s Tech Tutorials for more clear, actionable guides just like this one! Happy coding!