| title | Sign in to an Instance of SQL Server (Command Prompt) | |||||
|---|---|---|---|---|---|---|
| description | Learn about the sqlcmd utility. See how to use it in a command prompt to test connectivity to an instance of SQL Server. | |||||
| author | rwestMSFT | |||||
| ms.author | randolphwest | |||||
| ms.date | 06/05/2025 | |||||
| ms.service | sql | |||||
| ms.subservice | configuration | |||||
| ms.topic | how-to | |||||
| helpviewer_keywords |
|
[!INCLUDE SQL Server]
This article describes how to test connectivity to an instance of [!INCLUDE ssNoVersion], using the sqlcmd utility.
From a command prompt, enter the following command to connect by using Windows Authentication:
sqlcmd [/E] [/S servername]From a command prompt, enter the following command to connect by using Windows Authentication:
sqlcmd [/E] /S servername\instancename