Enable Dark Mode in SSMS: Step-by-Step Guide With Hidden Settings

Staring at a bright white screen all day? Your eyes deserve better. If you use SQL Server Management Studio (SSMS) for hours, switching to Dark Mode can make a huge difference. It looks cool. It feels better. And it can even help you focus.

In this guide, I’ll show you how to enable Dark Mode in SSMS step by step. We’ll also unlock a hidden setting that many people don’t know about.

TL;DR: SSMS has a partial Dark Mode built in. You can enable it from Tools > Options > Environment > General > Color theme. But the full Dark Mode is hidden and requires editing the ssms.pkgundef file. Close SSMS, edit the file, remove the dark theme exclusion line, save, and restart. Done!


Why Use Dark Mode in SSMS?

Let’s be honest. White screens can be harsh.

Here’s why many developers switch to Dark Mode:

  • Less eye strain during long coding sessions
  • Better focus on syntax highlighting
  • More comfortable when working at night
  • Modern look (because yes, it matters)

Now let’s turn it on.


Step 1: Check Your SSMS Version

Before we enable anything, check your version.

  • Open SSMS
  • Click Help
  • Select About

Dark Mode is available in SSMS 17 and later. The hidden full Dark Mode trick works especially well in SSMS 18 and newer.

If you’re running an old version, update first. It makes everything easier.


Step 2: Enable the Built-In Dark Mode (Easy Way)

Good news. SSMS already includes a Dark theme.

Here’s how to turn it on:

  1. Open SSMS
  2. Go to Tools
  3. Click Options
  4. Select Environment
  5. Click General
  6. Find Color theme
  7. Choose Dark
  8. Click OK

That’s it.

Your interface will change immediately.

But wait.

You may notice something strange. Some windows stay light. For example:

  • Object Explorer
  • Registered Servers
  • Template Explorer

That’s because this is only a partial Dark Mode.


Want the Full Dark Mode? Let’s Unlock the Hidden Setting

This is the fun part.

SSMS actually includes a more complete Dark theme. But Microsoft hid it. Why? Because it’s technically unsupported.

But it works. And many developers use it daily.

Important: Close SSMS before doing this.


Step 3: Locate the ssms.pkgundef File

You need to modify a configuration file.

Navigate to this folder (adjust version if needed):

C:\Program Files (x86)\Microsoft SQL Server Management Studio 18\Common7\IDE

In SSMS 19, the folder may reference 19 instead of 18.

Once inside the IDE folder, look for:

ssms.pkgundef

Image not found in postmeta

Step 4: Edit the Hidden Setting

Now we unlock the magic.

  1. Right-click ssms.pkgundef
  2. Select Open with
  3. Choose Notepad

Inside the file, press Ctrl + F and search for:

// Remove Dark Theme

You should see a block of lines under it.

It will look something like this:

// Remove Dark Theme
[$RootKey$\Themes\{GUID}]

To enable full Dark Mode:

  • Delete those lines entirely

Or comment them out by removing the restriction line.

Then:

  • Click File
  • Click Save
  • Close Notepad

Important: You may need administrator permissions to save changes.


Step 5: Restart SSMS

Open SSMS again.

Now go back to:

Tools > Options > Environment > General

Select Dark theme again if needed.

This time you should see a much more consistent Dark interface.

Object Explorer should now blend beautifully with the rest of the UI.


Customize Your Dark Mode Even More

Now that everything is dark, let’s make it perfect.

Change Font Colors

You can adjust syntax colors:

  1. Go to Tools
  2. Select Options
  3. Expand Environment
  4. Click Fonts and Colors

Here you can change:

  • Keywords color
  • Strings color
  • Comments color
  • Number color
  • Background color

Pro tip: Soft gray backgrounds reduce strain even more than pure black.


Common Problems (And Fixes)

1. SSMS Won’t Start

You may have deleted too much from the pkgundef file.

Fix:

  • Restore the file from backup
  • Or repair SSMS using the installer

Always create a backup before editing system files.

2. Some Panels Still Look White

This can happen with certain extensions.

Fix:

  • Update SSMS
  • Update or disable extensions

3. Theme Option Disappears

Re-check the pkgundef file.

You may have accidentally removed the wrong section.


Is the Hidden Dark Mode Safe?

Short answer: Yes, mostly.

It’s not officially supported. That means Microsoft might not fix small visual bugs.

But it does not:

  • Break databases
  • Affect queries
  • Change server behavior

It only changes how SSMS looks.

Thousands of developers use it without issues.


Bonus: Reset to Default Theme

Changed your mind?

To revert:

  • Select Blue or Light theme under Options

If you modified the pkgundef file:

  • Restore the original version
  • Or run an SSMS repair installation

Easy.


Why Microsoft Hid Full Dark Mode

You might wonder.

If it works, why hide it?

Here’s why:

  • Some legacy UI components don’t fully support themes
  • Occasional contrast issues
  • Small rendering inconsistencies

Instead of shipping a “half-perfect” feature, they limited it.

But developers love tweaking things. So here we are.


Tips for the Best Dark Mode Experience

  • Lower your monitor brightness slightly
  • Use a font like Consolas or Cascadia Code
  • Increase font size to reduce strain
  • Avoid pure #000000 backgrounds
  • Enable Windows Dark Mode too

Consistency across apps feels better.


Final Thoughts

Enabling Dark Mode in SSMS is simple.

The built-in version takes seconds.

The hidden full version takes two minutes.

And the difference is huge.

Your eyes will thank you.

Your workspace will look modern.

And you might even enjoy writing queries a bit more.

So go ahead. Flip the switch. Welcome to the dark side.