Connecting DataGrip to SQL Server Express LocalDB

First you need to check if you LocalDB instance is ready for connection. Locate SqllocalDB.exe and run the SqllocalDB.exe i command in terminal. You will see the list of available LocalDB instances on the server which you are connecting to.


Say we want to connect to the v11.0 instance. First we need to check its state by running SqllocalDB.exe i v11.0 command.


As you can see by examining the State field, right now the instance is stopped. Remember that by default every LocaDB instance is terminated after several minutes of inactivity. This behavior can be changed, but now we need to start the instance by running SqllocalDB.exe s v11.0


It’s ready, so let’s launch DataGrip.

Invoke the database view by pressing Alt+1 and click + to add a new datasource, then choose SQL Server (jTds).


In the connection window we first select LocalDB in the dropdown next to the URL field. Then we go to the Instance field and select the instance to connect to, in our case, v11.0.


Then, go to the Advanced tab and find the DOMAIN option and set it to the name of the machine where the instance is installed. If the instance is on your local machine, use the name of your computer.


The only thing left to do is to enter the access credentials and then click Test connection.




Your DataGrip Team
The Drive to Develop


This entry was posted in Tutorial and tagged , , . Bookmark the permalink.

One Response to Connecting DataGrip to SQL Server Express LocalDB

  1. Justin says:

    Thank you!!! :D
    I <3 JetBrains

Leave a Reply

Your email address will not be published. Required fields are marked *