How to specify a Port Number to Connect to SQL Server Instance

To specify the port when connecting to a SQL Server instance, use a comma to separate the server name or IP and the port.
For example:


Or you can use IP and the port number:,6789

For named instances, you usually connect by specifying the server name and instance name:


If you specify the port that the named instance is using, there is no need to specify the instance name, because each instance on a server uses a different port: