VSCode - Connect to a Remote Linux Server
by
Jeremy Canfield |
Updated: December 07 2025
| VSCode articles
Assuming your laptop is Windows, create a file C:\users\<your Windows username>\.ssh\config
Host server1
HostName server1.example.com
User <your username on the remote server>
In VSCode, install the Remote - SSH extension.
C:\users\<your username>\vscode\<your Windows username>.code-workspace
{
"folders": [
{
"uri": "vscode-remote://ssh-remote+<the name of the Host in your C:\users\<your Windows username>\.ssh\config file>/home/<your username on the remote server> "
}
],
"remoteAuthority": "ssh-remote+<remote server DNS hostname or IP address>",
"settings": {}
}
In Windows Explorer, double click on the <your Windows username>.code-workspace file you created. This will open another instance of VS Code. Follow the prompts in VSCode to establish the connection to the remote Linux server.
Did you find this article helpful?
If so, consider buying me a coffee over at 