How to Install SQL Server on Windows Server 2025

SQL Server 2022 is Microsoft’s latest on-premises database engine, and Windows Server 2025 is the ideal host platform for it. The two products share the same support lifecycle, both integrate natively with Azure Arc, and Windows Server 2025’s improved storage stack and SMBDirect support allow SQL Server to extract maximum I/O throughput from modern NVMe and RDMA-capable hardware. Whether you are standing up a new database environment, migrating from an older release, or building a development sandbox, understanding every stage of the installation process — from edition selection through post-install verification — saves hours of troubleshooting and future re-work. This guide walks you through the full installation of SQL Server 2022 on Windows Server 2025, covering edition comparison, prerequisite validation, feature selection, service account design, authentication configuration, and firewall hardening.

SQL Server 2022 Edition Comparison

Microsoft ships SQL Server 2022 in four main editions. Selecting the right one before you download the ISO prevents licensing headaches later.

  • Express: Free, limited to 10 GB data per database, 1 GB RAM, and four CPU cores. Best for small applications and learning. No SQL Server Agent, no advanced HA features.
  • Developer: Free, full Enterprise feature set, but licensed only for development and testing — never production. Ideal for pre-production environments and home labs.
  • Standard: Commercial license, supports up to 24 cores and 128 GB RAM. Includes Basic Availability Groups (two nodes, single database), SQL Server Agent, and replication.
  • Enterprise: Commercial license, unlimited cores and memory (hardware limit), full Always On Availability Groups, in-memory OLTP, columnstore, advanced compression, and Intelligent Query Processing.

For this tutorial the Developer edition is used so you can follow every step without incurring licensing cost. The installation steps are identical for Standard and Enterprise.

Prerequisites

  • Windows Server 2025 Standard or Datacenter, fully patched (run sconfig and install all updates).
  • .NET Framework 4.7.2 or later — verify with: Get-WindowsFeature Net-Framework-45-Features
  • A local administrator account or a domain account in the local Administrators group.
  • At least 6 GB free on the system drive for the SQL Server binaries.
  • Separate volumes recommended for data (D:SQLData), log (E:SQLLog), and tempdb (F:SQLTempDB).
  • SQL Server 2022 ISO or installer downloaded from microsoft.com.

Verify .NET and Windows features before starting:

# Confirm .NET 4.7+ is present
(Get-ItemProperty 'HKLM:SOFTWAREMicrosoftNET Framework SetupNDPv4Full').Release

# Install required Windows features
Install-WindowsFeature -Name NET-Framework-45-Core, NET-Framework-45-ASPNET `
    -IncludeManagementTools

Step 1 — Mount the ISO and Launch Setup

Mount the SQL Server 2022 ISO using the built-in Windows mounting capability, then launch the setup wizard.

# Mount the ISO
$iso = Mount-DiskImage -ImagePath "C:ISOsSQLServer2022-x64-ENU-Dev.iso" -PassThru
$driveLetter = ($iso | Get-Volume).DriveLetter
Write-Host "ISO mounted at $driveLetter"

# Launch interactive setup
Start-Process -FilePath "$($driveLetter):setup.exe" -Wait

The SQL Server Installation Center opens. Click Installation in the left panel, then New SQL Server stand-alone installation or add features to an existing installation.

Step 2 — Product Key and License Terms

On the Product Key page select Developer (or enter your commercial key for Standard/Enterprise). Accept the license terms and opt-in or out of Microsoft Update. On the Install Rules page, resolve any warnings — a common one is the Windows Firewall warning, which you will address manually after installation.

Step 3 — Feature Selection

On the Feature Selection page, choose the following components for a typical database server:

  • Database Engine Services — the core SQL Server engine (required).
  • SQL Server Replication — needed for transactional or merge replication scenarios.
  • Full-Text and Semantic Extractions for Search — if full-text indexes are required.
  • SQL Server Agent — job scheduler (installed automatically with Database Engine).
  • Management Tools — install SSMS separately from aka.ms/ssms for the latest version.

Leave Analysis Services, Reporting Services, and Integration Services unchecked unless they are needed — they significantly increase installation footprint and attack surface.

Step 4 — Instance Configuration

Choose between a Default instance (named MSSQLSERVER, connect with just the server name) or a Named instance (connect with SERVERNAMEInstanceName). Use the default instance for single-purpose servers. Use named instances when multiple SQL Server versions must coexist on the same host.

# Unattended install example specifying a named instance
.setup.exe /Q /ACTION=Install /FEATURES=SQLENGINE,REPLICATION `
  /INSTANCENAME="SQLPROD" `
  /SQLSVCACCOUNT="DOMAINsvc-sql" `
  /SQLSVCPASSWORD="P@ssw0rd123!" `
  /AGTSVCACCOUNT="DOMAINsvc-sqlagt" `
  /AGTSVCPASSWORD="P@ssw0rd123!" `
  /SECURITYMODE=SQL `
  /SAPWD="Sa!P@ssw0rd2025" `
  /SQLSYSADMINACCOUNTS="BUILTINAdministrators" `
  /IACCEPTSQLSERVERLICENSETERMS

Step 5 — Service Account Configuration

Service accounts control what Windows identity the SQL Server engine runs as. Best practices on Windows Server 2025:

  • Use a Group Managed Service Account (gMSA) for domain-joined servers — no password rotation required.
  • Use NT SERVICEMSSQLSERVER (virtual account) for standalone servers — minimal privilege, no domain required.
  • Avoid Local System and NT AUTHORITYNETWORK SERVICE in production — they carry excessive privilege.
# Create a gMSA (run on a domain controller)
New-ADServiceAccount -Name "svc-sqlengine" `
    -DNSHostName "sqlserver.corp.local" `
    -PrincipalsAllowedToRetrieveManagedPassword "SQL2025$" `
    -Enabled $true

# Install the gMSA on the SQL Server host
Install-ADServiceAccount -Identity "svc-sqlengine"
Test-ADServiceAccount -Identity "svc-sqlengine"

In the setup wizard, enter DOMAINsvc-sqlengine$ (note the trailing $) with a blank password for the SQL Server and SQL Agent service accounts.

Step 6 — Authentication Mode

On the Database Engine Configuration page, choose Mixed Mode if applications connect with SQL logins, or Windows Authentication Mode for pure Kerberos/Active Directory environments. Mixed Mode is more common in heterogeneous environments. Set a strong sa password — the account is disabled by default in Mixed Mode but should still have a strong password. Add the server’s administrator account to SQL Server administrators.

Step 7 — Data Directories

Change the default data, log, and tempdb directories on the Database Engine Configuration > Data Directories and TempDB tabs:

  • Data root: D:SQLData
  • User database log: E:SQLLog
  • TempDB data files: F:SQLTempDB — match the number of files to the number of logical CPU cores (up to 8).
  • Backup: G:SQLBackup

Click Next through the remaining pages and then Install. Installation typically takes 5–15 minutes.

Step 8 — Enable TCP/IP Protocol

By default, TCP/IP may be disabled. Enable it with SQL Server Configuration Manager or PowerShell:

# Load the SQL Server SMO assemblies
Import-Module SqlServer

# Enable TCP/IP for the default instance
$smo = 'Microsoft.SqlServer.Management.Smo.'
$wmi = New-Object ($smo + 'Wmi.ManagedComputer')
$uri = "ManagedComputer[@Name='$env:COMPUTERNAME']/ServerInstance[@Name='MSSQLSERVER']/ServerProtocol[@Name='Tcp']"
$Tcp = $wmi.GetSmoObject($uri)
$Tcp.IsEnabled = $true
$Tcp.Alter()

# Restart the SQL Server service to apply
Restart-Service -Name MSSQLSERVER -Force

Alternatively, open SQL Server Configuration Manager (SQLServerManager16.msc), expand SQL Server Network Configuration > Protocols for MSSQLSERVER, right-click TCP/IP, and choose Enable. In the IP Addresses tab, set the port to 1433 under IPALL.

Step 9 — Configure Windows Firewall

# Allow SQL Server default instance port
New-NetFirewallRule -DisplayName "SQL Server 2022 - Default Instance" `
    -Direction Inbound `
    -Protocol TCP `
    -LocalPort 1433 `
    -Action Allow `
    -Profile Domain,Private

# Allow SQL Server Browser (needed for named instances)
New-NetFirewallRule -DisplayName "SQL Server Browser" `
    -Direction Inbound `
    -Protocol UDP `
    -LocalPort 1434 `
    -Action Allow `
    -Profile Domain,Private

# Confirm rules are active
Get-NetFirewallRule -DisplayName "SQL Server*" | Select-Object DisplayName, Enabled, Action

Step 10 — Test the Connection with SSMS

Install SQL Server Management Studio (SSMS 20+) on an admin workstation, then connect to the server:

  1. Open SSMS. In the Connect to Server dialog, enter the server name (or IP address for TCP/IP connections).
  2. Select Windows Authentication or SQL Server Authentication with the sa account.
  3. Click Connect. The Object Explorer should populate with system databases.
# Quick connectivity test from PowerShell (requires SqlServer module)
Invoke-Sqlcmd -ServerInstance "localhost" -Query "SELECT @@VERSION AS Version, GETDATE() AS ServerTime" -TrustServerCertificate

A successful result returns the SQL Server version string and the current server timestamp, confirming that the engine is listening, authentication is working, and the firewall permits the connection.

Conclusion

Installing SQL Server 2022 on Windows Server 2025 is a structured process that rewards careful planning. Edition selection dictates your HA options and licensing cost, service account choice determines your security posture, and correct data directory layout is the single biggest factor in ongoing I/O performance. By following the steps above — mounting the ISO, selecting the right features, configuring a gMSA service account, enabling TCP/IP, and opening the firewall on port 1433 — you have a production-ready SQL Server instance that aligns with Microsoft’s current security baseline. The next steps in hardening this server include enabling Transparent Data Encryption (TDE), configuring SQL Server Audit, and scheduling automated backups with SQL Server Agent or Ola Hallengren’s maintenance solution.