[BUG] [Desktop] Windows: terminal pane on SSH session fails with tilde-expansion error for ~/.ssh/id_rsa
Status Fixed / completed
Reported on v2.1.284
Maintainer reply None cached
Workaround ✓ Mentioned in description ↑
Activity 0 comments · opened Sep 30, 2026 · closed Sep 30, 2026
Summary
In the Claude desktop app on Windows, the integrated terminal pane doesn't work for sessions on an SSH connection. It shows a tilde-expansion error about ~/.ssh/id_rsa and never connects. The agent session on the same SSH connection works fine.
Environment
- Client: Claude desktop app (Code tab), Windows laptop
- Remote: Ubuntu 24.04.5 LTS VM (kernel 6.8.0-142-generic), non-root user; remote CLI
2.1.284 - SSH key auth;
%USERPROFILE%\.ssh\configsets an absoluteIdentityFile C:/Users/<name>/.ssh/id_rsafor every host, including this one
Steps to reproduce
- Add an SSH connection in the desktop app and start a session on it. The agent session works: it can run commands on the remote.
- Open that session's terminal pane.
Expected: a shell on the remote host.
Actual: a tilde-expansion error that names ~/.ssh/id_rsa; no shell.
Evidence that the failure happens on the Windows client before any connection
- The remote daemon log (
~/.claude/remote/run/<id>/remote-server.log) has no PTY/terminal/shell entries for the terminal-pane attempts. Only the normal startup[shellenv]lines appear. The request never reaches the remote. - No stored setting contains
~/.ssh/id_rsa. A search of%USERPROFILE%\.claude.json,%USERPROFILE%\.claude\(includingsettings.json; it has nosshConfigskey) and%APPDATA%\Claudefound no identity-file value. The literal seems to come from a built-in default in the terminal code path, not from user config.
Workarounds tried (none helped)
- Explicit absolute
IdentityFilein~/.ssh/configfor this host, plus a full quit and relaunch from the system tray - Setting a user
HOMEenvironment variable toC:\Users\<name>, plus a full quit and relaunch
Related
- #48393: no way to edit or delete saved SSH connections. That's why the identity file can't be checked or fixed from the UI.