GuidesHosting choices

VS Code Remote-SSH: connect, server requirements and fixes

Connect VS Code to your server with Remote-SSH: glibc 2.28 and other server needs, what ~/.vscode-server holds, where Claude Code and Codex run, and fixes.

December 2, 2026The Everpod team
The short answer

Install Microsoft’s Remote - SSH extension (ms-vscode-remote.remote-ssh), run Remote-SSH: Connect to Host... from the Command Palette and pick a host from your ~/.ssh/config. VS Code then installs its server in ~/.vscode-server on the machine, runs it as your user, and opens no new port. The server needs Linux with glibc 2.28 and libstdc++ 3.4.25 or later (Ubuntu 20.04, Debian 10, RHEL 8 and newer; not Alpine) and at least 1 GB of RAM. Extensions such as Claude Code and Codex run on the server, so they use the server’s files and the server’s sign-in. The extension is licensed for Microsoft’s VS Code only.

Check the server before you install anything

Most failed first connections are a server VS Code no longer supports, so check it first. Microsoft’s Linux prerequisites ask for kernel 4.18, glibc 2.28, libstdc++ 3.4.25 and tar, and for Remote - SSH also an OpenSSH server, bash, and curl or wget. On the server:

ldd --version
Copied

The first line ends in the glibc version. The Remote FAQ dates the rule: since VS Code 1.99 (March 2025), the servers it downloads run only on distributions built on glibc 2.28 or later, “for example, Debian 10, RHEL 8, or Ubuntu 20.04.”

ServerStatus in Microsoft’s Linux table
Ubuntu 20.04 and later, x86_64 or Arm64
Supported
Debian 10 and later
Supported
RHEL, CentOS, Oracle Linux 8 and later
Supported
openSUSE Leap, SLES 15
Supported
Raspberry Pi OS 10 and later (32-bit Arm)
Works; some extensions may not, because of x86 native code
Ubuntu 18.04
Not supported: glibc too old
Debian 9, CentOS 7, RHEL 7, Oracle Linux 7
Not supported: glibc and libstdc++ too old
Alpine
Not supported over SSH (only in Dev Containers and WSL)

The Remote - SSH page and the extension’s Marketplace listing still print an older list (Debian 8, Ubuntu 16.04, CentOS 7), while the Linux page marks Ubuntu 18.04 and CentOS 7 unsupported and the FAQ ties the glibc 2.28 floor to VS Code 1.99. The FAQ’s rule is the dated one. Arm servers are listed, but Microsoft calls them a preview because extensions may carry only x86_64 native code.

On memory, the SSH page says 1 GB of RAM is required and recommends 2 GB with two cores. That is VS Code’s own need. A coding agent running beside it needs more: Claude Code alone asks for 4 GB, as Claude Code in VS Code covers.

On your laptop you need VS Code itself and an OpenSSH client; PuTTY is not supported on Windows. Key-based login is the recommended route. Making a key and a host entry are in generating an SSH key and the SSH config file.

Install the extension and connect

Install Remote - SSH from the Extensions view, or from a terminal on your laptop:

code --install-extension ms-vscode-remote.remote-ssh
Copied

Microsoft’s first step is to check that plain ssh works from a terminal, because VS Code uses the same client and can only do what it can. Remote - SSH reads your ~/.ssh/config, so a host with a short name there is a host you can pick from a list:

Host agent-box
    HostName 203.0.113.10
    User you
    IdentityFile ~/.ssh/id_ed25519
Copied

203.0.113.10, you and the key path are placeholders for your own. Then:

  1. Open the Command Palette and run Remote-SSH: Connect to Host..., then choose agent-box. Remote-SSH: Add New SSH Host... writes a new entry for you if the host is not in the file yet.
  2. If VS Code cannot tell what the server runs, it asks you to pick the platform. Choose Linux. The answer is saved in the remote.SSH.remotePlatform setting.
  3. The first connection takes longer while VS Code installs its server on the machine.
  4. Open a folder on the server with File > Open.... The bottom-left of the status bar now names the host, and the integrated terminal is a shell on the server.

File > Close Remote Connection ends the session. Hosts you have used are listed in the Remote Explorer, where a folder can be reopened directly.

What it puts on the server

Connecting installs the VS Code Server, a separate copy from any VS Code already on the machine, in ~/.vscode-server in your home directory (older versions used ~/.vscode-remote). Remote extensions and the server’s per-host data live there too. Per the FAQ, it runs as the user you logged in as, is “started and stopped by VS Code”, is not added to any login or startup script, and needs no port opened “beyond those used by these well-known, secure transports”: everything travels inside your SSH connection.

The server is downloaded from update.code.visualstudio.com and vscode.download.prss.microsoft.com over HTTPS, and extensions from marketplace.visualstudio.com and *.gallerycdn.vsassets.io. Microsoft’s pages differ on what happens when the server cannot reach those. The FAQ says the extension falls back to downloading the server on your laptop and copying it across; the troubleshooting page says the remote machine “must have internet access to be able to download the VS Code Server and extensions from the Marketplace.” For extensions, the FAQ’s way around that is Extensions: Install from VSIX... with a file you brought over.

VS Code installs and updates the server itself when it connects, so there is nothing to maintain on the machine. Removing it is the standard fix for many failures (below).

Which extensions run where, and whose sign-in they use

VS Code splits extensions into two kinds. UI extensions (themes, keymaps, snippets) “always run on the user’s local machine.” Workspace extensions, which read the workspace’s files and run its tools, the coding agents among them, run where the folder is: on the server. In a remote window, an extension of the second kind that you have only on your laptop shows dimmed under Local - Installed; the cloud button, Install Local Extensions in SSH: agent-box, copies them over. To have some on every host you connect to, list them in your local settings:

"remote.SSH.defaultExtensions": [
  "anthropic.claude-code",
  "openai.chatgpt"
]
Copied

The consequence for coding agents is that the server is where they live. The Claude Code extension’s commands run on the server, it edits the server’s files, and its settings and sign-in are the server’s ~/.claude: Anthropic’s VS Code page tells you to edit ~/.claude/settings.json “on that system, not on your local computer” in a window connected to an SSH host, and on Linux the sign-in is stored in ~/.claude/.credentials.json. Codex works the same way: OpenAI’s auth page says “The CLI and extension share the same cached login details,” kept in ~/.codex/auth.json or the system’s credential store. So if you already signed in to the CLI on the server, the extension in a Remote-SSH window is signed in too, with the same account. Being signed in on your laptop does not carry over.

One exception runs the other way: an extension that keeps a key with VS Code’s own secret storage keeps it on your laptop, even when the extension runs on the server, because that API “will always store the secrets on the client side.” Developer: Show Running Extensions shows which side each extension is running on. Each agent’s remote quirks, including sign-in callbacks that need a forwarded port, are in the Claude Code and the Codex extension guides.

Opening a web UI the agent started

When an agent starts a dev server on the server’s localhost:3000, run Forward a Port from the Command Palette, or use Add Port in the Ports view. A notification says which local port to open. It is not always the same number: in VS Code’s own example, 3000 is “mapped to port 4123 on localhost since 3000 was already in use”.

A forward made this way lasts as long as the window. For ports you always want, add a LocalForward line to the host’s block in ~/.ssh/config, such as LocalForward 127.0.0.1:3000 127.0.0.1:3000, which also applies to a plain ssh session. Opening the same app from a phone, or without VS Code open, takes another route, compared in opening a localhost app on a remote server.

When it fails

Remote-SSH: Show Log, or the Remote - SSH channel of the Output panel, shows the real error behind every message below.

“Could not establish connection”

Could not establish connection to agent-box: The VS Code Server failed to start.
Copied

The troubleshooting page’s first move is Remote-SSH: Kill VS Code Server on Host, which removes the server so the next connection installs a fresh one and which it says “can fix a wide range of issues.” Before that, rule out two causes: a glibc older than 2.28 (the table above), and a server set up to disallow running scripts from /tmp, where VS Code writes its install script.

It hangs before connecting

VS Code may be waiting for input you cannot see: a password, a two-factor code, or a key passphrase when no SSH agent is running. Turn on remote.SSH.showLoginTerminal, which “displays the terminal whenever VS Code runs an SSH command,” and type the answer there. If it still hangs, the troubleshooting page has you set both of these in settings.json and retry:

"remote.SSH.showLoginTerminal": true,
"remote.SSH.useLocalServer": false
Copied

“administratively prohibited” in the log

open failed: administratively prohibited: open failed
Copied

The server’s SSH daemon forbids TCP forwarding, which VS Code needs to talk to its server. Set AllowTcpForwarding yes in /etc/ssh/sshd_config on the server and restart the SSH service, keeping your current session open until a new login works (if it does not come back, the SSH service guide helps). Open Remote - SSH, the alternative for other editors, needs the same line.

The server is too old

On a server below glibc 2.28, such as Ubuntu 18.04 or CentOS 7, the current VS Code Server does not start. Upgrading the distribution is the supported fix. The FAQ describes a workaround it calls “not an officially supported usage scenario”: build a sysroot with newer libraries, install it and patchelf on the server, and point VSCODE_SERVER_CUSTOM_GLIBC_LINKER, VSCODE_SERVER_CUSTOM_GLIBC_PATH and VSCODE_SERVER_PATCHELF_PATH at them. VS Code then connects and shows a banner saying the connection is unsupported. An old distribution is also past its security updates, which matters more on a machine where an agent runs commands.

The server download fails

By default the server is fetched on the remote machine first, and if that fails, on your laptop, then copied over. On a server whose outbound traffic is filtered, skip the server-side attempt with the remote.SSH.localServerDownload setting, which the FAQ says can be set “to always download locally and then transfer it.” Microsoft’s pages do not print the setting’s values, so pick that option in the Settings editor.

The wrong platform was picked

If you answered the platform question wrongly, or VS Code guessed wrong, the answer is stored per host in your settings. Change it to Linux, using the host’s name from your SSH config:

"remote.SSH.remotePlatform": {
  "agent-box": "linux"
}
Copied

A stuck lock or a half-installed server

When the server will not start, or a connection waits on a lock that never clears, start clean. Remote-SSH: Uninstall VS Code Server from Host... kills its processes and deletes its folder. Microsoft does not say what happens to the integrated terminal’s shells, but they run under that server, so expect a job started in a VS Code terminal to end with it; a long agent session is safer in tmux. If you cannot connect at all, do the same from a plain SSH session. This force-stops your VS Code Server processes on the server and deletes ~/.vscode-server, including the extensions installed on that host; your projects are not touched:

kill -9 $(ps aux | grep vscode-server | grep $USER | grep -v grep | awk '{print $2}')
rm -rf ~/.vscode-server
Copied

Where the home directory is on a shared network filesystem, an open report on the extension’s tracker, from a site with homes on AFS, was pointed at remote.SSH.useFlock and remote.SSH.lockfilesInTmp and at installing the server in a different directory; the reporter found a server install path under /tmp helped.

Extensions fail to install on Fedora 45

An open report from November 24, 2026, #11983, describes installs on a minimal Fedora 45 failing with Signature verification failed with 'UnknownError' error. in the log. The reporter traces it to Fedora defaulting to OpenSSL 4 while VS Code’s signature check needs OpenSSL 3’s libssl.so.3, and installing openssl3-libs fixed it. Microsoft had not replied as of December 2, 2026.

git push hangs

Microsoft lists this as a known limitation: with a passphrase on the SSH key used for git, VS Code’s pull and sync may hang. Use git push in the terminal, clone over HTTPS, or use a key without a passphrase.

VSCodium, Cursor and other editors

Remote - SSH is not open source, and its licence reads: “You may not use the software if you do not have a license for Microsoft Visual Studio Code.” The FAQ says the same of the server: “It is not intended or licensed for use by other clients.” Builds of VS Code from other publishers therefore use their own remote extensions; for VSCodium, the common one is Open Remote - SSH. If you would rather not install an editor on the laptop at all, code-server runs VS Code on the server and opens it in a browser.

Run Claude Code, Codex, OpenCode, Pi, Hermes or OpenClaw on an always-on developer pod.

A developer pod is a permanent cloud computer (VPS), set up and secured for you, with your pick of Claude Code, Codex, OpenCode, Pi, Hermes and OpenClaw installed. Run more agents at once than your laptop can hold, and keep them working when it’s closed. From $24 a month, built in about ten minutes.