Table of Contents

Updated by Tracy King on Apr 09, 2024

This page focus on providing professional & effective solutions to help you find missing or retrieve product key for Microsoft SQL Server. Follow to find your Microsoft SQL Server product now.

Does SQL Server Have a License Key? 

Yes, Microsoft SQL Server has a product key. However, it's not like the Windows operating system or Office applications, an SQL license key is embedded in the activation wizard of the software. 

As a result, you actually can't directly find the license code in the admin center. So where do you find the SQL product key after installation? 

Continue reading and we'll discuss this, making it easy for you to locate the license of SQL Server 2019/2017/2016 and even older versions.

How Do I Find My SQL Server Product Key? You Have 3 Ways Here for Help

Before starting the guide, we searched online and found that most solutions provided for finding Microsoft SQL Server product keys are described in an obscure manner. 

Here, we collected 3 practical ways and make it clear for you to follow for retrieving SQL Server license:

#1. Use 1-Click SQL Server Product Key Finder
#2. Use Registry
#3. Use Powershell

Applies to: SQL Server 2019/2017/2016/2014/2012/2008 R2/2008/2003/2000, etc.

Your Quick Guide: 

  • For the easiest and most efficient way to find your Microsoft SQL Server product key, third-party product key finder - EaseUS Key Finder is here to help.
  • To find the SQL Server product key for free, try the tips in Method 2 and Method 3. 

Now, let's get started finding SQL Server product keys in Windows Server computers.

#1. Use 1-click Microsoft SQL Server Product Key Finder - EaseUS Key Finder

 Find Microsoft SQL Server Product Key in 1-Click

EaseUS Key Finder enables all levels of Microsoft SQL Server users, Windows Server, and Windows users to simply find product keys of installed operating system, software, and programs in simple clicks.

  Free Download

Support Windows 11/10/8/7

Besides finding SQL Server key, this software also works to:

  • Find product key for Windows 11/10/8.1/8/7 and all Windows Server systems.
  • Find Office 365/2019/2017, etc., product key. 
  • Find Adobe serial key for Photoshop, Premiere, After Effects, etc. 
  • Find browser Chrome, Edge, Firefox account and password.
  • Find WiFi codes, etc.

How to Find Microsoft SQL Server Product Key:

Step 1. Click "Application" tab under "Registry Key".

find software product key 1

Step 2. View Applications Registry Keys on the right panel. EaseUS Key Finder will show all keys of installed software. Copy the targeted serial numbers. Also, you can click "Print" or "Save".

find software product key 2

Does your company need to backup all files, settings, applications, profiles for Windows Server 2019, 2016, 2012 (R2)? Read on to backup to AWS or local server.

server backup

#2. Use Registry to Find SQL Server Product Code

Free Solution to Find SQL Server Product Code

The Registry Editor on Windows Server computer also works to find the SQL Server product key for you. Be careful when you browse the Registry Editor with the following steps to locate SQL Server key value:

Note that the registry path may differ depends on different SQL Server versions.

Step 1. Right-click the Windows icon and select "search".

Step 2. Type regedit and hit Enter to open Registry Editor.

Step 3. Navigate to the path and find the ProductCode value:

HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Microsoft SQL Server\MSSQL.1\Setup

Step 4. Double-click the ProductCode value, then, you can view the SQL Server key.

Find SQL Server product key in Registry

#3. Use Powershell to Get Back the SQL Server Product Key Information

Command Line Solution for Finding SQL Server Key

This method works to retrieve the SQL Server product key from an existing installation on your client or Server machine. Mostly, this takes place when you have an old Server to move or relocate and no one remembers where your license is.

Here are the steps to find your SQL Server product key using PowerShell:

Step 1. Right-click the Windows icon and select "PowerShell".

Step 2. Type the following command in PowerShell and hit Enter:

function GetSqlServerProductKey {
    ## function to retrieve the license key of a SQL 2008 Server.
    param ($targets = ".")
    $hklm = 2147483650
    $regPath = "SOFTWARE\Microsoft\Microsoft SQL Server\100\Tools\Setup"
    $regValue1 = "DigitalProductId"
    $regValue2 = "PatchLevel"
    $regValue3 = "Edition"
    Foreach ($target in $targets) {
        $productKey = $null
        $win32os = $null
        $wmi = [WMIClass]"\\$target\root\default:stdRegProv"
        $data = $wmi.GetBinaryValue($hklm,$regPath,$regValue1)
        [string]$SQLver = $wmi.GetstringValue($hklm,$regPath,$regValue2).svalue
        [string]$SQLedition = $wmi.GetstringValue($hklm,$regPath,$regValue3).svalue
        $binArray = ($data.uValue)[52..66]
        $charsArray = "B","C","D","F","G","H","J","K","M","P","Q","R","T","V","W","X","Y","2","3","4","6","7","8","9"
        ## decrypt base24 encoded binary data
        For ($i = 24; $i -ge 0; $i--) {
            $k = 0
            For ($j = 14; $j -ge 0; $j--) {
                $k = $k * 256 -bxor $binArray[$j]
                $binArray[$j] = [math]::truncate($k / 24)
                $k = $k % 24
            $productKey = $charsArray[$k] + $productKey
            If (($i % 5 -eq 0) -and ($i -ne 0)) {
                $productKey = "-" + $productKey
        $win32os = Get-WmiObject Win32_OperatingSystem -computer $target
        $obj = New-Object Object
        $obj | Add-Member Noteproperty Computer -value $target
        $obj | Add-Member Noteproperty OSCaption -value $win32os.Caption
        $obj | Add-Member Noteproperty OSArch -value $win32os.OSArchitecture
        $obj | Add-Member Noteproperty SQLver -value $SQLver
        $obj | Add-Member Noteproperty SQLedition -value $SQLedition
        $obj | Add-Member Noteproperty ProductKey -value $productkey

#1. For SQL Server 2012, replace line 5 and 16 with the following line:

  • $regPath = "SOFTWARE\Microsoft\Microsoft SQL Server\110\Tools\Setup"
  • $binArray = ($data.uValue)[0..16]

#2. For SQL Server 2014, replace DigitalProductID with the real instance name in Registry and replace line 5 with the following line:

  • $regPath = "SOFTWARE\Microsoft\Microsoft SQL Server\MSSQL12.[YOUR SQL INSTANCE NAME]\Setup"

Step 3. Type  GetSqlServerProductKey and hit Enter.

Find SQL Server product key in PowerShell

After this, you'll see the product key of your SQL Server on the PowerShell window.

Finding SQL Server Product Key Is Possible, Pick the Easiest Way for Help Now

In many cases, finding the SQL Server product key is essential. On this page, we collected 3 reliable methods for you to follow and recover the missing product code for SQL Server.

  • For the easiest way out, EaseUS Key Finder is an ideal solution that you can apply for a try.

  Free Download

Support Windows 11/10/8/7

  • For a free SQL Server product key finder, Registry and Powershell are ready here to help.

Was This Page Helpful?

Updated by Tracy King

Tracy became a member of the EaseUS content team in 2013. Being a technical writer for over 10 years, she is enthusiastic about sharing tips to assist readers in resolving complex issues in disk management, file transfer, PC & Mac performance optimization, etc., like an expert.

Read full bio

About EaseUS Key Finder

EaseUS Key Finder offers complete solutions for you to efficiently find Windows or Windows Server product keys, discover Offce, Adobe, and other installed software serials, and find WiFi codes, etc, successfully in simple clicks.

Product Reviews