Click on the banner to learn about and purchase my database training on Azure

SQL Server Management Studio (SSMS) - How to activate the Dark theme (Dark Theme Support)

Views: 26.504 views
Reading Time: 4 minutes

Hello people,
All right with you ?

Today I was checking the news of blogs that I recommend and ended up seeing a super cool tip on Leka's Blog I decided to share here with you too, which consists of enabling the Dark theme in the SQL Server Management Studio (SSMS) interface, as already exists in Visual Studio for some versions.

Since the release of SSMS 2016, released in July, it was already possible to choose Light and Blue themes and this generated a community expectation about the Dark theme release, which did not happen. Not satisfied, Leka opened a connect at Microsoft requesting the release of the Dark theme and then he decided to post the solution for that, while Microsoft does not officially make it available on SSMS as the theme already exists but is disabled by default as it still needs to be tweaked.

Themes officially available on SSMS 2016 13.0.16106.4

How to enable Dark theme in SSMS 2016

If you want to activate the Dark theme in your Management Studio to check the "preview" version of the theme, follow the steps below:

  • Download the SQL Server Management Studio (SSMS) 2016
  • Open your favorite text editor using an Administrator user

    If you forget to open the file in Administrator mode, Notepad ++ helps you 🙂

  • Open the file “C: \ Program Files (x86) \ Microsoft SQL Server \ 130 \ Tools \ Binn \ ManagementStudio \ ssms.pkgundef” (if using SSMS 18, the file is located in the “C: \ Program Files ( x86) \ Microsoft SQL Server Management Studio 18 \ Common7 \ IDE ”)
  • Locate the entry // Remove Dark theme and comment out (inserting // at the beginning of the line) or remove the contents of the file starting at this line and ending at the entry // Remove DacFx 11.0 binding path to avoid conflicts with 13.0 assemblies, as shown below:

    Note: Our friend Reginaldo Silva warned us about a bug using Debugger on this theme after making these settings. To prevent this from happening, he tells us NOT to comment on the line [$ RootKey $ \ Debugger \ LaunchHooks110] 🙂

  • Save the file and restart SSMS 2016

Ready! Now your SSMS 2016 has Dark theme support.

See some prints of this theme in use (remembering that it is still a preview, and is not fully completed):

How to use Dark theme colors in any version of SSMS

Even if you are not using the 2016 version of SQL Server Management Studio (I see no reason for that), you can still use Dark theme colors in your version of SSMS. Earlier versions do not have Themes feature, but you can edit the themes and colors of the Editor formatting or simply import a file with the settings you already made, which I found on the blog. SentryOne.

Manual setup

If you don't want to import the settings and want to do it manually, these are the theme color settings:
Comment: RGB (255,175,45)
Keyword: RGB (127,176,228)
Script Comment: RGB (255,175,45)
Keyword Script: Cyan RGB (0,255,255)
Script string: Yellow RGB (255,255,0)
SQL Operator: RGB (199,199,199)
SQL Stored Procedure: RGB (128,255,128)
SQL String: Yellow RGB (255,255,0)
SQL System Function: RGB (220,1120,255)
SQL System Table: RGB (128,255,128)

Importing the configuration file

If you want to do it the easy way, just download the theme setting accessing this link and follow the steps below:

Select "Tools"> "Import and Export Settings ..." in the SQL Server Management Studio menu bar

Check the option “Import selected environment settings” and click Next

On this screen, I recommend saving your current settings so that you can revert back to those settings if you don't like the theme. To do this, just follow the screen below.

Click the "Browse" button and select the settings file you downloaded.

After selecting the file, it will be available on the next screen, under the “My Settings” folder

After clicking “Next”, the import interface will show what will be imported and changed in your SSMS settings

Ready. Import completed.

See how the SSMS query editor looked after doing this process.

That's it folks!
I hope you enjoyed this tip and even more.