image illustration of whale SQL server container with docker Windows 10

How to Set Up a Local SQL Server Container with Docker – Windows 10

It is quite simple to set up a local instance of SQL Server container with Docker on a Windows 10 machine.

Step 1: Docker

Download and install Docker. Be sure all check boxes are checked off. You will need wsl installed.  Once Docker is installed, it will ask you to restart your pc. Reboot your PC.

Step 2: Updates

When the PC reloads, you may get an error. WSL2 needs an update. click the link provided, or click here . It will ask to restart. Restart your PC again.

Step 3: Firewall

When your PC Reboots, Windows firewall will ask to allow access. click to allow access.

Step 4: Powershell

Open up Powershell and run as admin, enter code below and press Enter to install.

docker pull

Step 5: Run

Once installed in Powershell, type:

docker run -d -p 1433:1433 --name sql-server-2019-express -e "MSSQL_PID=Express" -e "SA_PASSWORD=MyTestPass@word" - e "ACCEPT_EULA=Y"

-p is the Port the SQL server will run on, the –name is the name of container, your SA_PASSWORD can be anything. Since this is locally done, no need to create logins.

To Connect to your new local SQL server

  1. Download and install Microsoft SQL Server Management Studio .
  2. Open up Microsoft Sql Server Management.
  3.  A pop up Connect to Server or click File > Connect Object Explorer
  4. Fill in credentials
    1. Server type – Database Engine
    2. Server name –,1433 or localhost,1433
    3. Authentication – SQL Server Authentication: Login – sa; Password – MyTestPass@word
  5. Click Connect and you should be in.

If for some reason, you cannot connect, validate that your docker container is running:

We're building an AI-powered Product Operations Cloud, leveraging AI in almost every aspect of the software delivery lifecycle. Want to test drive it with us? Join the ProdOps party at