Setup: Install SQL Server 2025 and SSMS
Install SQL Server 2025 Developer and SQL Server Management Studio 22, and connect to your server with Windows authentication.
Novice · Operating System · Database · Updated
After this lesson you can
- Install SQL Server and SSMS and connect with Windows authentication
Key takeaways
- SQL Server stores your apps' data. Its free Developer edition has every feature, and it's licensed for learning, development and testing.
- SSMS is a separate app, where you look at your databases and run SQL.
- A Basic installation makes your Windows account the server's administrator, so you sign in with Windows Authentication and no extra password.
- Connect to
localhostwith Trust server certificate checked: on your own computer, trusting your server's self-made certificate is safe.
Windows only. A database server stores data and answers questions about it. In this course you use SQL Server, Microsoft's database server, in its free Developer edition. It has every feature of the paid editions, and it's licensed for learning, development and testing, not for running a real business.
SQL Server Management Studio (SSMS) is the app you use to look at your databases and run SQL. It's a separate install.
Install SQL Server
In Git Bash, run:
winget install -e --id Microsoft.SQLServer.2025.Developer --interactive
Click Yes if Windows asks whether the app may make changes. The SQL Server installer opens.
- If it asks which edition to install, choose a Developer edition.
- Choose the Basic installation type.
- Accept the license terms.
- Leave the install location as it is, and click Install. The installer downloads SQL Server, then installs it. This takes 10 to 20 minutes.
- When it finishes, it shows a page of connection details, with Instance name: MSSQLSERVER. Click Close. Don't click Install SSMS: you install SSMS with winget next.
A Basic installation makes your Windows account the server's administrator. You sign in to SQL Server as yourself, with no extra password to remember. That's called Windows authentication.
SQL Server runs in the background as a Windows service, and starts every time your computer starts.
Install SSMS
winget install -e --id Microsoft.SQLServerManagementStudio.22
Click Yes if Windows asks whether the app may make changes. This takes a few minutes.
Connect to your server
Open SQL Server Management Studio 22 from the Start menu. The first time, it may ask you to sign in; you can skip that.
The Connect to Server window opens. Fill it in like this:
| Field | Value |
|---|---|
| Server type | Database Engine |
| Server name | localhost |
| Authentication | Windows Authentication |
| Encryption | Mandatory |
| Trust server certificate | Checked |
Click Connect. Object Explorer, on the left, shows your server with a Databases folder under it.
Why "Trust server certificate"? SSMS encrypts the connection, and checks the server's certificate to be sure it's talking to the right server. A Basic installation gives your server a certificate it made itself, which nobody else vouches for. On your own computer, trusting it is safe.
Check your work
Click New Query on the toolbar. In the query window, type:
SELECT @@VERSION;
Press F5 (or click Execute). The Results pane shows one row that starts with Microsoft SQL Server 2025.
The databases this course uses, Northwind, AdventureWorksLT and BooksPlus, are added in the Databases chapter, when you need them.
Common problems
| What you see | What to do |
|---|---|
The certificate chain was issued by an authority that is not trusted |
Check Trust server certificate in the Connect to Server window. |
A network-related or instance-specific error occurred |
SQL Server isn't running. Click Start, type Services, open it, find SQL Server (MSSQLSERVER), and click Start. |
Login failed for user |
Choose Windows Authentication, not SQL Server Authentication. |
| The installer says your computer needs a restart | Restart Windows, then run the install command again. |
localhost doesn't connect, but the server is running |
Try the server name . (a single period). It also means "this computer". |
Check yourself
2 questions to try on the lesson page.
So what
Every app you build from Module 1 on keeps its data in SQL Server, and SSMS is where you'll look at that data and try out your SQL before you put it in your code.
Key terms
- SQL Server
- SQL Server Management Studio
- SQL Server Express and Developer Editions
- Windows Authentication