Running a local MySQL server on Windows 11 enables development and testing of database-backed applications without relying on shared infrastructure, reducing risk to staging or production data while keeping iteration fast.
On Windows, the official MySQL Installer downloads the selected MySQL components, registers MySQL Server as a Windows service, and applies the initial configuration (networking, authentication, accounts) during the setup wizard, with upgrades and maintenance handled from the same UI.
Administrative rights and a few configuration choices materially affect the final result, including TCP port conflicts (default 3306), firewall exposure, and the default authentication plugin (caching_sha2_password) used for accounts.
Steps to install MySQL server on Windows:
- Download the MySQL Installer for Windows from the official MySQL downloads page.
https://dev.mysql.com/downloads/installer/
Web installer downloads components during setup; Full installer includes the packages for offline installs.
- Run the downloaded installer with administrative privileges.
Declining elevation commonly prevents service registration and leaves the server partially configured.
- Select a setup type that includes MySQL Server.
Developer Default installs MySQL Server plus tools such as MySQL Workbench and MySQL Shell; Server only keeps the footprint smaller.
- Confirm MySQL Server appears in the product selection list and continue.
- Execute the download and installation of the selected products.
MySQL Installer may prompt to install prerequisites (such as Microsoft Visual C++ runtimes) before the server can run.
- Choose a configuration profile for the machine.
Development Computer favors local development defaults; Server Computer and Dedicated Computer allocate more resources to mysqld.
- Set the TCP/IP port for the server instance.
Port 3306 conflicts with an existing database service prevent startup until the port is changed or the conflicting service is stopped.
- Leave the Windows firewall port closed for local-only use.
Opening the firewall rule allows inbound connections to the chosen port, which increases exposure if the machine is on untrusted networks.
- Keep the default authentication method unless legacy clients require mysql_native_password.
caching_sha2_password is the modern default for MySQL 8.x; legacy authentication may be required for older connectors and tools.
- Set a strong password for the root account.
Losing the root password typically requires a reset workflow that involves stopping the Windows service and starting mysqld with special options.
- Create a separate administrative user for day-to-day work.
Keeping root reserved for administration reduces accidental changes and simplifies auditing.
- Configure the Windows service name and startup type.
Service names commonly look like MySQL80 or MySQL84, and server config is typically stored under C:\ProgramData\MySQL.
- Apply the configuration until the installer reports completion.
- Confirm the MySQL service shows as running in Services.
PowerShell verification:
PS C:\> Get-Service -Name MySQL* Status Name DisplayName ------ ---- ----------- Running MySQL80 MySQL80
- Verify local login and basic server operation from a terminal.
PS C:\> mysql -u root -p Enter password: Welcome to the MySQL monitor. Commands end with ; or \g. ##### snipped ##### mysql> SELECT 1; +---+ | 1 | +---+ | 1 | +---+ 1 row in set (0.00 sec) mysql> exit Bye
If mysql is not on PATH, run mysql.exe from the server’s bin directory under C:\Program Files\MySQL.
Mohd Shakir Zakaria is a cloud architect with deep roots in software development and open-source advocacy. Certified in AWS, Red Hat, VMware, ITIL, and Linux, he specializes in designing and managing robust cloud and on-premises infrastructures.
