How to use darks theme ?
Although it’s not officially supported by Microsoft, the Dark theme is also available in SSMS 2016, SSMS 17 and SSMS 18.
Follow following steps to get dark theme:
- Close Microsoft SQL Server Management Studio (the abbreviation used is SSMS in following text)
- Open text editor in admin rights (I use Notepad++)
- Locate
ssms.pkgundef
configuration file and open it. Configuration file is located at the following locations:- SSMS 2016:
C:\Program Files (x86)\Microsoft SQL Server\130\Tools\Binn\ManagementStudio
- SSMS 17:
C:\Program Files (x86)\Microsoft SQL Server\140\Tools\Binn\ManagementStudio
- SSMS 18:
C:\Program Files (x86)\Microsoft SQL Server Management Studio 18\Common7\IDE
- SSMS 2016:
- Once the file is opened in the text editor, scroll down and find section of the code under the “Remove Dark Theme” heading, add “// ” (without quotation marks) at the beginning of the first line and save the file
- Open SSMS and select
Dark
Color Theme (Tools –> Options: Environment –> General)
NOTE! When SSMS is upgrated this configuration file will set back to its defaults.
Powershell scripts for different versions
Open PowerShell admin rights and use following scripts.
SSMS 2016
powershell -Command "(gc 'C:\Program Files (x86)\Microsoft SQL Server\130\Tools\Binn\ManagementStudio\ssms.pkgundef') -replace '\[\`$RootKey\`$\\Themes\\{1ded0138-47ce-435e-84ef-9ec1f439b749}\]', '//[`$RootKey`$\Themes\{1ded0138-47ce-435e-84ef-9ec1f439b749}]' | Out-File 'C:\Program Files (x86)\Microsoft SQL Server\130\Tools\Binn\ManagementStudio\ssms.pkgundef'"
SSMS 17
powershell -Command "(gc 'C:\Program Files (x86)\Microsoft SQL Server\140\Tools\Binn\ManagementStudio\ssms.pkgundef') -replace '\[\`$RootKey\`$\\Themes\\{1ded0138-47ce-435e-84ef-9ec1f439b749}\]', '//[`$RootKey`$\Themes\{1ded0138-47ce-435e-84ef-9ec1f439b749}]' | Out-File 'C:\Program Files (x86)\Microsoft SQL Server\140\Tools\Binn\ManagementStudio\ssms.pkgundef'"
SSMS 18
powershell -Command "(gc 'C:\Program Files (x86)\Microsoft SQL Server Management Studio 18\Common7\IDE\ssms.pkgundef') -replace '\[\`$RootKey\`$\\Themes\\{1ded0138-47ce-435e-84ef-9ec1f439b749}\]', '//[`$RootKey`$\Themes\{1ded0138-47ce-435e-84ef-9ec1f439b749}]' | Out-File 'C:\Program Files (x86)\Microsoft SQL Server Management Studio 18\Common7\IDE\ssms.pkgundef'"