One read of Claude Documentationclaude-docs-20261128T050710Z
1 pages moved out of 299 read.
Pages moved
1
significant first
Pages read
299
in this capture
Captured
05:07 UTC
Corpus hash
56fe5c397883
corpus-hash
What this read moved
1-1 of 1third-party/claude-desktop/ssh-remote-sessions Changed · +69 / -12 lines
### Keep a long turn running while Claude Desktop is disconnected
from line 15
15153. **Run.** The remote server starts the engine on the host with the policy from your managed configuration and the inference credential that Claude Desktop passes, if it passes one. Every file read, edit, shell command, and git operation runs on the host, in the working directory the user chose there. Claude Desktop connects to [managed MCP servers](https://claude.com/docs/third-party/claude-desktop/extensions.md#managed-mcp-servers-admin) from the device and exposes them to the engine as tools.
16164. **Stream.** Claude's responses and tool output stream back to Claude Desktop. Permission prompts appear in Claude Desktop, and the engine waits on the host until the user answers.
1717
18The engine keeps running on the host through a dropped SSH link, device sleep, or the user quitting Claude Desktop. It finishes the current turn, or stops at a permission prompt, then idles. While Claude Desktop is disconnected or closed, an idle engine can still start a turn by itself, for example when scheduled work comes due (a `/loop` task, say) or when a background command ends. An engine that starts while [`scheduledTasksEnabled`](https://claude.com/docs/third-party/claude-desktop/configuration#scheduledtasksenabled) is `false` starts without Claude Code's scheduling tools, so `/loop` can't schedule work there. An engine that already runs keeps those tools until Claude Desktop replaces it. Whatever else can start a turn still can, a background command's end included. While Claude Desktop is disconnected or closed, a credential that it passed is not refreshed, so a turn that outlives that credential, or starts after it expires, can fail with an authentication error. A restart of the app for an update counts as a quit.
18The engine keeps running on the host through a dropped SSH link, device sleep, or the user quitting Claude Desktop. It finishes the current turn, or stops at a permission prompt, then idles. While Claude Desktop is disconnected or closed, an idle engine can still start a turn by itself, for example when scheduled work comes due (a `/loop` task, say) or when a background command ends. An engine that starts while [`scheduledTasksEnabled`](https://claude.com/docs/third-party/claude-desktop/configuration#scheduledtasksenabled) is `false` starts without Claude Code's scheduling tools, so `/loop` can't schedule work there. An engine that already runs keeps those tools until Claude Desktop replaces it. Whatever else can start a turn still can, a background command's end included. While Claude Desktop is disconnected or closed, a credential that it passed is not refreshed, so a turn that outlives that credential, or starts after it expires, can fail with an authentication error (see [Keep a long turn running while Claude Desktop is disconnected](#keep-a-long-turn-running-while-claude-desktop-is-disconnected)). The engine also keeps running through a restart of the app for an update.
1919
2020When the user reopens the session after a quit, Claude Desktop rejoins the engine or replaces it, unless it refuses to start the session:
2121
from line 22
2222* **Rejoins**: on a macOS or Linux device, Claude Desktop 2.42304.0 or later tries to rejoin an engine that 2.42304.0 or later started. On a Windows device, Claude Desktop 3.1623.0 or later tries to rejoin an engine that 3.1623.0 or later started. If it rejoins, a turn still running goes on. It can fail to rejoin, for example after some Claude Desktop updates or after a change to the managed configuration since the engine started.
2323* **Replaces**: if Claude Desktop doesn't rejoin the engine, for example because a version older than the minimums above started it, Claude Desktop ends the engine and starts a fresh one from the transcript stored on the host. A turn that finished while the app was closed is shown in full, and a turn that still runs is cut short. If the turn stays stopped, the user sends a message to continue it.
2424
25While Claude Desktop 2.42304.0 or later stays open, it can start a fresh engine and tell Claude to continue when the engine ends in the middle of a turn, for example after the host restarts, even if nobody is at the device. It doesn't look first for commands that the old engine left running, and it stops after three continues or 24 hours.
26
27After a change to your managed configuration, Claude Desktop can end an engine that it can't rejoin and start a fresh one, even in the middle of a turn. Claude Desktop 5.11492.0 or later can then tell Claude to continue the turn, even if the user quit the app earlier and doesn't reopen the session. For example, Claude Desktop can do so soon after a launch, when its window shows the session and nobody is at the device.
28
29On a Linux host, Claude Desktop 6.6395.0 or later can also continue a stopped turn without the user. If it finds after a launch that the engine ended in the middle of a turn, it can start a fresh engine and tell Claude to continue, even if nobody opens the session. Before it does so, it makes several checks. Among others, all of these must hold:
30
31* The app closed through a crash, a force quit, a power cut, a restart of Claude Desktop for an update, or in some other way than an ordinary quit by the user.
32* Claude Desktop confirms on the host that the old engine has ended, and finds nothing that the engine started still running there.
33* The host's [launcher](https://claude.com/docs/third-party/claude-desktop/code.md#start-code-sessions-through-a-corporate-launcher) didn't start the session.
34* The turn first stopped less than 24 hours ago, and Claude Desktop has continued it fewer than three times.
35
36A turn that Claude Desktop continues by itself keeps the session's permission mode, as far as your managed configuration still allows it, so in auto mode or bypass permissions mode Claude can run commands and call tools without asking. A command that was cut off, such as a migration or a delete, may be half done, or may still run where Claude Desktop can't see it. Claude can start it again. The `disableBypassPermissionsMode` and `autoModeEnabled` keys limit what Claude can run without asking.
37
2538On a host that ends a user's processes at logout, the remote server and the engine end with the SSH connection that started them, so a turn in progress doesn't survive a disconnect. Linux hosts where systemd-logind's `KillUserProcesses` setting is `yes` and applies to the SSH user behave this way. To keep remote sessions running through a disconnect on such a host, ask the host's administrator to exempt the SSH user, for example by listing the user under `KillExcludeUsers` in the systemd-logind configuration.
2639
2740An idle engine stays on the host, and keeps any credential that Claude Desktop passed, until one of these happens:
2841
2942* The user archives or deletes the session while Claude Desktop is connected to the host.
30* The user reopens the session and Claude Desktop ends the engine to start a fresh one.
43* Claude Desktop ends the engine to start a fresh one.
3144* The host restarts.
3245* After an update that includes a new remote server, Claude Desktop replaces the host's remote server at a later connection. This ends the engines under the old server. Claude Desktop can put the replacement off while it believes that work is running on that host.
3346* After an update that includes a newer Claude Code, the user sends a message in the session. Claude Desktop 4.29.0 or later can then replace the engine with the newer version, if the engine has reported that it has no background or scheduled work.
from line 51
3851
3952On a Linux or macOS host, if Claude Desktop stayed open, it rejoins the running engine when it reconnects after device sleep or a dropped SSH link. It catches up from the buffer, and loads the part of the conversation that the buffer has dropped from the transcript stored on the host. If it can't load all of it, the session shows "Some output produced while you were disconnected may be missing here."
4053
41Some tool calls wait for an answer from Claude Desktop, and fail while it is disconnected:
54Some tool calls need an answer from Claude Desktop before they run. While it is disconnected, they wait up to a limit. At the limit they fail, except that file tools inside your allowed folders can go on:
4255
43* **File tools under a folder restriction**: if you set [`allowedWorkspaceFolders`](https://claude.com/docs/third-party/claude-desktop/configuration#allowedworkspacefolders), Claude Desktop checks each file read, search, and edit before it happens. While Claude Desktop is disconnected, each of these calls waits up to 10 minutes and then fails.
44* **Tools that your policy sets to ask**: if [`builtinToolPolicy`](https://claude.com/docs/third-party/claude-desktop/configuration#builtintoolpolicy) sets a bare tool name, such as `Bash`, to `ask`, Claude Desktop is consulted before each call to that tool. While Claude Desktop is disconnected, each call waits up to 10 minutes and then fails.
56* **File tools under a folder restriction**: if you set [`allowedWorkspaceFolders`](https://claude.com/docs/third-party/claude-desktop/configuration#allowedworkspacefolders), Claude Desktop checks each file read, search, and edit before it happens. With Claude Desktop 6.6395.0 or later, on a Linux or macOS host, an engine that gets no answer within about 10 seconds checks the path itself, against the list that was in force when that engine started. A call inside your allowed folders goes on, subject to your [read-only entries](#read-only-folders-on-the-remote-host) and the session's permission mode, and a call outside them fails. In a session that runs in its own git worktree, an edit outside that worktree fails too. A running session keeps the allowed folders that were in force when its engine started, even while Claude Desktop is connected. If you change the list or its read-only entries, Claude Desktop, once it has read the change, tells each running engine that it can reach to stop checking paths itself. An engine that hasn't been told, for example while Claude Desktop is closed or disconnected, keeps checking paths itself against its old list. A session moves to the changed list only when Claude Desktop starts a new engine for it. Until then, the old engine can keep running on the host under the old list. To end it yourself, see [Files and processes on the remote machine](https://code.claude.com/docs/en/desktop#files-and-processes-on-the-remote-machine). Before Claude Desktop 6.6395.0, each call waits up to 10 minutes and then fails. That still holds in some cases, which include a Windows host, an engine that an earlier version started, and a running engine that has been told to stop checking paths itself.
57* **Tools that your policy sets to ask**: if [`builtinToolPolicy`](https://claude.com/docs/third-party/claude-desktop/configuration#builtintoolpolicy) sets a bare tool name, such as `Bash`, to `ask`, Claude Desktop is consulted before each call to that tool. A call made while Claude Desktop is disconnected waits for up to a week and then fails, and the turn pauses with it. On a Linux or macOS host, when Claude Desktop reconnects after device sleep or a dropped SSH link, the user gets the approval prompt. If the user quits and reopens Claude Desktop during the wait, the call is refused, and Claude can try it again or go on without it. A call that another check by Claude Desktop refuses first fails at that check's limit. For example, under `allowedWorkspaceFolders`, a file edit that the folder check stops fails at that check's limit, and one that it lets go on waits for the approval. Before Claude Desktop 6.6395.0, the call waits up to 10 minutes and then fails.
4558* **Tools from MCP servers that run on the device**: these include your managed MCP servers (see [Where MCP servers run in a remote session](#where-mcp-servers-run-in-a-remote-session)). While Claude Desktop is disconnected, each call to one of their tools fails after about 30 seconds. The 30-second limit requires Claude Desktop 2.2553.0 or later.
4659
47For a task that uses these tools, have the user keep the device awake and connected. For other limits, see [Limits while Desktop is disconnected](https://code.claude.com/docs/en/desktop#limits-while-desktop-is-disconnected).
60For a task that depends on calls that wait or fail in this way, have the user keep the device awake and connected. For other limits, see [Limits while Desktop is disconnected](https://code.claude.com/docs/en/desktop#limits-while-desktop-is-disconnected).
4861
4962### Account that a remote session runs under
5063
from line 102
89102* Each call to a tool that [`builtinToolPolicy`](https://claude.com/docs/third-party/claude-desktop/configuration#builtintoolpolicy) sets to `ask` by its bare name, such as `Bash`
90103* Each call to a tool from an MCP server that runs on the device
91104
92While Claude Desktop is disconnected, each of these calls waits and then fails, after up to 10 minutes for file tools and tools set to `ask` (for each limit, see [How a remote session works](#how-a-remote-session-works)). Claude receives the failure as the call's result, and a further call of the same kind waits again, which delays the `Stop` hook. For a task that makes these calls, have the user keep the device awake and connected.
105While Claude Desktop is disconnected, each of these calls waits up to its limit and then fails, except that a file call inside your allowed folders can go on (for the limits, and for when that exception applies, see [How a remote session works](#how-a-remote-session-works)). Claude receives a failure as the call's result, and a further call of the same kind waits again, which delays the `Stop` hook, by up to a week for a tool set to `ask`. For a task that depends on calls that wait or fail in this way, have the user keep the device awake and connected.
93106
94107To cover every user of a host, put the hooks in [Claude Code managed settings](https://code.claude.com/docs/en/settings#settings-files) on the host instead, which on a Linux host is the file `/etc/claude-code/managed-settings.json`. If the host already has Claude Code managed settings, add the hooks to those and leave [`parentSettingsBehavior`](https://code.claude.com/docs/en/settings-reference#parentsettingsbehavior) as it is, set or unset. Changing it changes how those settings combine with the policy that Claude Desktop supplies. If the host has none yet, also set `parentSettingsBehavior` to `"merge"` in the managed settings that you create.
95108
from line 415
402415
403416When the configured credential is a refused kind, the session fails at session start unless a launcher starts Claude Code. The card is [SSH sessions can't use your model provider settings](#ssh-sessions-can%E2%80%99t-use-your-model-provider-settings). Where `claudeCodeProcessWrapperEnabled` is on and a Linux or macOS host names no launcher, the card is `Your organization's launcher isn't set up on <host>` instead.
404417
405When a credential that Claude Desktop passed expires during a turn, Claude Desktop obtains a new one on the device, by re-running a [credential helper](https://claude.com/docs/third-party/claude-desktop/credential-helper.md) or using a sign-in's refresh token, and sends it over the SSH connection.
418When a credential that Claude Desktop passed expires during a turn, Claude Desktop obtains a new one on the device, by re-running a [credential helper](https://claude.com/docs/third-party/claude-desktop/credential-helper.md) or using a sign-in's refresh token, and sends it over the SSH connection. It can do so only while it is connected (see [Keep a long turn running while Claude Desktop is disconnected](#keep-a-long-turn-running-while-claude-desktop-is-disconnected)).
406419
407420Where the host's [launcher](https://claude.com/docs/third-party/claude-desktop/code.md#start-code-sessions-through-a-corporate-launcher) starts Claude Code, Claude Desktop passes no inference credential and refuses no credential kind. Claude Code uses the credential that the launcher or the SSH account's own environment sets, or, on Google Cloud's Agent Platform, the account's application default credentials.
408421
from line 448
435448
436449With [`claudeCodeProcessWrapperEnabled`](https://claude.com/docs/third-party/claude-desktop/code#start-code-sessions-through-a-corporate-launcher) on, a launcher that the host names starts Claude Code. Where the key is off or unset, or Claude Desktop finds no launcher on the host, a new session signs in with the host's profile. To keep sessions on a launcher, name it on every host that `sshHostAllowlist` allows, and set the key in the device's [managed profile](https://claude.com/docs/third-party/claude-desktop/admin-console.md#devices-with-a-managed-profile) so that users can't turn it off. To have sessions refused where no launcher is found, also set `inferenceBedrockAwsDir` to a folder outside the user's home directory, as under **For the whole deployment**. Claude Desktop learns whether a host names a launcher, and which, from the host itself, as the account that signed in, so it can't make sure that a host with no launcher really has none, or that the launcher is yours. Keeping Claude Code from running without your launcher stays the work of your own controls on the host.
437450
451### Keep a long turn running while Claude Desktop is disconnected
452
453A turn is Claude's work from the user's message, or from another start such as a background command that finishes, until Claude finishes responding. The engine is the Claude Code process on the host. Claude Desktop is disconnected while the device sleeps, the SSH link is down, or the app is closed.
454
455While Claude Desktop is disconnected, a turn keeps making model requests for as long as your provider or gateway accepts the credential that the engine already holds. Whoever issues the credential sets how long that is. Once the credential is refused, the turn fails with an authentication error.
456
457> [!NOTE]
458>
459> Where the host's [launcher](https://claude.com/docs/third-party/claude-desktop/code.md#start-code-sessions-through-a-corporate-launcher) starts Claude Code, or the engine signs in with the host's own AWS profile (see [Amazon Bedrock with a named profile](#amazon-bedrock-with-a-named-profile)), Claude Desktop passes no inference credential, so it renews none. How long a turn can keep making model requests then depends on the credential that the launcher or the SSH account sets, or on the credentials that the host's profile supplies. See [Inference credentials on the remote host](#inference-credentials-on-the-remote-host).
460
461For a turn that may outlast the credential, have the user keep the device awake and connected. While Claude Desktop is connected, it renews an expired credential when the provider or gateway answers with HTTP 401 (on Amazon Bedrock, with its expired-token 403; from your LLM gateway, with 401 or 403), and the engine retries the request. Check what the renewal needs in your deployment:
462
463* **Credential helper**: the renewal needs the [helper](https://claude.com/docs/third-party/claude-desktop/credential-helper.md) to issue a new token when it runs again, and `inferenceCredentialHelperSilentRefreshEnabled` left at `true` (see [Turn off mid-session re-runs](https://claude.com/docs/third-party/claude-desktop/credential-helper.md#turn-off-mid-session-re-runs))
464* **Sign-in through your identity provider**: the renewal needs a refresh token from that provider
465* **Requests that go through your LLM gateway**: the renewal needs the gateway to answer an expired token with HTTP 401 or 403. Renewal after a 403 requires Claude Desktop 5.11492.5 or later.
466
467To let a turn finish with the device asleep or Claude Desktop closed, the engine needs a credential that outlives the turn. This goes against the warning under [Inference credentials on the remote host](#inference-credentials-on-the-remote-host), which advises short-lived tokens over a long-lived key. You can get such a credential in these ways:
468
469* **A credential helper that issues a longer-lived token**: where your provider or gateway allows it, have the helper issue a token that stays valid for the longest turn that you want to allow, plus at least the [`inferenceCredentialHelperTtlSec`](https://claude.com/docs/third-party/claude-desktop/configuration#inferencecredentialhelperttlsec) value, which is in seconds. The added time covers a token that was already in Claude Desktop's cache when the turn started. That key sets how long Claude Desktop caches the helper's output on the device, not how long the token stays valid. Prefer this option to a static key, because the token still expires.
470* **A static API key or bearer token**: for a provider where the table under [Inference credentials on the remote host](#inference-credentials-on-the-remote-host) lists one. It works until your provider or gateway stops accepting it, and everyone who receives the same configuration uses the same one, so revoking it cuts off model requests for all of them.
471* **A longer token lifetime at the issuer**: with single sign-on or another in-app sign-in through your identity provider or cloud provider, only that issuer can lengthen the token's lifetime. Claude Desktop gets a new token when the old one is about to expire or has been refused, so a turn can start on a token that is near its end. A longer lifetime makes that less likely but doesn't rule it out. For [Workforce Identity sign-in](https://claude.com/docs/third-party/claude-desktop/vertex.md#in-app-workforce-identity-sign-in), the token lasts for the workforce pool's session duration in Google Cloud (1 hour by default).
472
473Before each turn that the user starts, Claude Desktop [checks the helper's token](https://claude.com/docs/third-party/claude-desktop/credential-helper.md#timeouts-and-caching) and renews one whose cache time is nearly over. Where that check doesn't apply, the engine keeps the token that it holds until your provider or gateway refuses it. A turn can then start on a token that is near its end, whatever time you add, in cases such as these:
474
475* **The `inferenceCredentialHelperTtlSec` value is 120 seconds or less**: Claude Desktop skips the check. Keep the value above 120.
476* **The user has quit and reopened Claude Desktop since the engine started**: a restart of the app for an update has the same effect. For an engine that Claude Desktop rejoins, the check goes by the token that Claude Desktop held when it rejoined, not by the older one that the engine holds. Have the user start the long turn in a new session. Its engine starts on a token no older than the `inferenceCredentialHelperTtlSec` value.
477* **Claude starts the turn by itself**: for example, when a background command finishes. Allow for the time from the user's last message to the end of the last such turn.
478
479> [!WARNING]
480>
481> With any of these options, the engine keeps the credential on each host that your [`sshHostAllowlist`](https://claude.com/docs/third-party/claude-desktop/configuration#sshhostallowlist) admits and where a user has started a session. It keeps it for as long as it runs, including while it idles. If someone copies the credential from the host, the copy keeps working after the engine ends, until the credential expires or you revoke it at your provider or gateway.
482
483With any of these credentials, the turn still stops at a permission prompt, tool calls that need an answer from Claude Desktop still wait or fail, and no message reaches the engine until Claude Desktop reconnects. On a host that ends a user's processes at logout, the turn ends with the SSH connection, whichever credential the engine holds. For those tool calls and the host setting to check, see [How a remote session works](#how-a-remote-session-works).
484
438485## Managed configuration on the remote host
439486
440487Most of the policy that Claude Desktop applies to a local Code session applies on the remote host too. The [Code page](https://claude.com/docs/third-party/claude-desktop/code.md#how-configuration-propagates) describes how each key reaches Claude Code.
from line 725
678725* `git` on the path, for git features.
679726* A home directory that the SSH user can write to and run programs from, with about 1 GB of disk space for the three Claude Code versions the app keeps and a fourth while an update installs. A home directory mounted `noexec` doesn't work.
680727
681The device needs the OpenSSH client (`ssh` and `ssh-keygen`). Claude Desktop runs the first `ssh` on the user's `PATH`. On Windows, that is the first `ssh.exe`, and a `.bat`, `.cmd`, or `.ps1` wrapper named `ssh` isn't run. For the `ssh` that carries the connection on a Windows device, see [Prepare Windows devices for the OpenSSH client](#prepare-windows-devices-for-the-openssh-client).
728The device needs the OpenSSH client (`ssh` and `ssh-keygen`). Claude Desktop runs the first `ssh` on the user's `PATH`. On macOS and Linux, while `sshClientPath` is unset, Claude Desktop can also run `/usr/bin/ssh`. On Windows, the first `ssh` is the first `ssh.exe`, and a `.bat`, `.cmd`, or `.ps1` wrapper named `ssh` isn't run. For the `ssh` that carries the connection on a Windows device, see [Prepare Windows devices for the OpenSSH client](#prepare-windows-devices-for-the-openssh-client).
682729
683730To pin a specific OpenSSH installation instead, set [`sshClientPath`](https://claude.com/docs/third-party/claude-desktop/configuration#sshclientpath) (beta, Claude Desktop 1.46388.1 or later) to the program's absolute path:
684731
from line 746
699746
700747Claude Desktop makes the SSH connection by running the device's OpenSSH client, so authentication uses the Kerberos (GSSAPI), certificate, and `ssh_config` support of your own OpenSSH build. The program is the one `sshClientPath` names, or else, on macOS and Linux, the first `ssh` on the user's `PATH`, and it must be OpenSSH 7.6 or later. On Windows, the device's OpenSSH client is the default in Claude Desktop 4.16336.0 or later, and only for hosts that are new to the device. See [Prepare Windows devices for the OpenSSH client](#prepare-windows-devices-for-the-openssh-client).
701748
749While `sshClientPath` is unset, Claude Desktop on macOS and Linux also runs `/usr/bin/ssh` in cases such as these:
750
751* **The first `ssh` on the `PATH` is a script**: the script makes the connection, and `/usr/bin/ssh` runs the commands, file transfers, and terminals on that connection.
752* **macOS denies the first `ssh` access to the local network**: macOS can do that to an `ssh` that isn't Apple's, such as Homebrew's. Claude Desktop then connects to the host with `/usr/bin/ssh`, so authentication and `ssh_config` support are those of `/usr/bin/ssh`. If the first `ssh` is a script, the script doesn't run for that connection. Claude Desktop can keep using `/usr/bin/ssh` for that host until Claude Desktop restarts. Requires Claude Desktop 2.9939.2 or later.
753* **macOS devices**: Claude Desktop runs `/usr/bin/ssh` to read the user's SSH configuration. This run makes no connection.
754
702755To use one client for every host, set [`sshTransport`](https://claude.com/docs/third-party/claude-desktop/configuration#sshtransport) (beta) to `system-openssh` or `builtin`. Both apply on every platform. A change applies to new connections, and sessions that are already connected keep their client.
703756
704757* **`system-openssh`**: use the device's OpenSSH client.
from line 764
711764* **The device can't start the OpenSSH client**: while `sshTransport` is unset or `auto` and `sshClientPath` is unset, the app uses the built-in client for every connection until Claude Desktop restarts. If the device can't start `ssh-keygen` either, connections fail at the host key check (see [SSH host key verification failed](#ssh-host-key-verification-failed)). Requires Claude Desktop 2.7032.0 or later.
712765* **Claude Desktop is installed from the Microsoft Store**: the built-in client makes the connection unless `sshTransport` is `system-openssh`. With `system-openssh`, the device's OpenSSH client makes the connection, but the app can't show its prompts for a password, a one-time code, or a key passphrase, or its question about a host key that isn't on record. Use a sign-in method that needs no prompt, such as a key held by the SSH agent, and have users connect to each host once from a terminal before adding it in the app, so that the host's key is in the user's `known_hosts` file.
713766
714Claude Desktop writes the following into the SSH user's home directory on the host. Each user who connects gets their own copy.
767Claude Desktop and the Claude Code engine write the following into the SSH user's home directory on the host. Each user who connects gets their own copy.
715768
716769| Path on the host | Contents |
717770| - | - |
from line 774
721774| `~/.claude/remote/plugins/<id>/` | Plugins synced from the device, in one folder for each Claude Desktop installation that connects |
722775| `~/.claude/remote/session-folders/` | The remote server's record of the folders that sessions have worked in, kept as small files. Requires Claude Desktop 4.16336.0 or later |
723776| `~/.claude/uploads/<session-id>/` | Files the user attached to a message. Not removed when the session ends |
777| `~/.ccd/t/` | Claude Code's temporary files, such as pasted images and background task output, on a Linux or macOS host where Claude Code can't use its own folder in the host's temporary directory. A restart of the host doesn't clear this folder. Requires Claude Desktop 6.6395.0 or later |
778| `~/.cache/claude-cli-nodejs/` on a Linux host, `~/Library/Caches/claude-cli-nodejs/` on a macOS host, `%LOCALAPPDATA%\claude-cli-nodejs\Cache\` on a Windows host | Claude Code's MCP server logs |
724779| `~/.claude/` and `~/.claude.json` | Claude Code's own data, including session transcripts. See [Data storage](https://claude.com/docs/third-party/claude-desktop/data-storage.md) |
725780
781Claude Code and the programs that it starts, such as MCP servers, can write elsewhere in the home directory too.
782
726783Each side of a remote session needs its own network access.
727784
728785* Devices installed with the regular installer must reach `downloads.claude.ai`: Claude Desktop downloads the remote server there and uploads it to the host. Devices installed with the [offline installer](https://claude.com/docs/third-party/claude-desktop/installation.md#offline-installation) don't: it bundles the remote server and the Claude Code engine for Linux x64 and arm64 hosts, and Claude Desktop uploads both. Hosts on other platforms still need the download, so an offline-installed device that cannot reach `downloads.claude.ai` fails the session with a message saying the installer doesn't include remote components for that platform.
from line 875
818875
819876* **Client version**: with no [`sshClientPath`](https://claude.com/docs/third-party/claude-desktop/configuration#sshclientpath), a usable client prints a version that starts with `OpenSSH_for_Windows_` and is 9.4 or later. That is Microsoft OpenSSH, also called Win32-OpenSSH. Run `ssh -V` in a Command Prompt window on a device, signed in as the user. If that output is anything else, run `ssh.exe -V` in `%SystemRoot%\System32\OpenSSH` and in `%ProgramFiles%\OpenSSH`: Claude Desktop uses the first usable client that it finds, on the `PATH`, then in those two folders in that order. If you set `sshClientPath`, run that program with `-V` instead. With `sshTransport` unset or `auto`, or in Claude Desktop 3.1623 and earlier, it has to pass the same test. With `system-openssh`, it can instead be an OpenSSH client that isn't Microsoft's. Such a client has to meet the conditions in [Use the OpenSSH client of Git for Windows](#use-the-openssh-client-of-git-for-windows) or in [Use an OpenSSH client installed per user](#use-an-openssh-client-installed-per-user). Each section names the Claude Desktop version that it requires.
820877* **Devices without a usable client**: on a Windows device with no usable OpenSSH client and no `sshClientPath`, the built-in client is used, whatever `sshTransport` says. If the device can't run `ssh-keygen` either, connections fail at the host key check (see [SSH host key verification failed](#ssh-host-key-verification-failed)). Add the **OpenSSH Client** optional feature in Windows and install pending Windows updates, or install [Microsoft's newer build](https://learn.microsoft.com/en-us/troubleshoot/windows-server/system-management-components/upgrade-in-box-openssh-to-latest-openssh-release). Run the version check again, then have users quit and reopen Claude Desktop. Hosts that the device first reached without a usable client stay on the built-in client. To move them, set `sshTransport` to `system-openssh`.
821* **Application control**: `ssh` shows its prompts through three helper programs that ship with Claude Desktop, `claude-ssh-askpass.exe`, `claude-ssh-broker.exe`, and `claude-ssh-proxy.exe`. Allow them in your application control policy by their publisher, Anthropic, PBC. Their folder changes with each update, and the files carry no product name or version. Allow the `ssh.exe` that the version check found, and the `ssh-keygen.exe` beside it, too. If Windows refuses to start the helpers, the app can't ask for a key passphrase, and `ssh` refuses a host whose key isn't on record. If `sshTransport` is `system-openssh`, sign-ins that need a password or a one-time code fail. Otherwise, if the app itself can't start the helper, the built-in client makes those sign-ins. See [This computer won't start Claude's SSH sign-in helper](#this-computer-won%E2%80%99t-start-claude%E2%80%99s-ssh-sign-in-helper).
878* **Application control**: `ssh` shows its prompts through three helper programs that ship with Claude Desktop, `claude-ssh-askpass.exe`, `claude-ssh-broker.exe`, and `claude-ssh-proxy.exe`. Allow them in your application control policy by their publisher, Anthropic, PBC, and let the rule match any product name and any file version. Their folder changes with each update. With Claude Desktop 6.28899.2 or later, each file's version information gives the company `Anthropic, PBC`, the product `Claude`, and the file version `1.0.0.0`, which helps you recognize the files, for example in an alert. The file version stays `1.0.0.0` when Claude Desktop updates. The helper programs of Claude Desktop 6.6395.1 and earlier have no version information, so a rule that also requires a product name or a file version doesn't match them. Allow the `ssh.exe` that the version check found, and the `ssh-keygen.exe` beside it, too. If Windows refuses to start the helpers, the app can't ask for a key passphrase, and `ssh` refuses a host whose key isn't on record. If `sshTransport` is `system-openssh`, sign-ins that need a password or a one-time code fail. Otherwise, if the app itself can't start the helper, the built-in client makes those sign-ins. See [This computer won't start Claude's SSH sign-in helper](#this-computer-won%E2%80%99t-start-claude%E2%80%99s-ssh-sign-in-helper).
822879* **Firewall and endpoint security**: if your endpoint security software blocks `claude-ssh-askpass.exe`, `claude-ssh-broker.exe`, or `claude-ssh-proxy.exe` after a Claude Desktop update, have it trust their publisher, `Anthropic, PBC`, rather than a path or a file hash. See [Endpoint security software](https://claude.com/docs/third-party/claude-desktop/installation.md#endpoint-security-software). Allow `ssh.exe` outbound wherever you allow Claude Desktop itself. With `sshTransport` unset or `auto` and no `sshClientPath`, the built-in client takes over where Windows refuses to start `ssh.exe`, but not where `ssh.exe` starts and can't reach the network. Each connection that the OpenSSH client makes then fails or times out, and the card points to the network or the host, not to `ssh.exe`.
823880* **While `ssh.exe` can't reach the network**: a host that stays on the built-in client still connects. For other hosts, set `sshTransport` to `builtin`, for Windows devices only, until you can allow `ssh.exe` (see **One value for all platforms** below). A host that the device first reaches meanwhile stays on the built-in client afterwards. The session's terminal runs `ssh.exe` with either client, so it stays blocked until then.
824881* **Key files**: `ssh` doesn't read a PuTTY `.ppk` key file. Unless the host stays on the built-in client because of that file (see **PuTTY key files** above), export the key in OpenSSH format, and have the user select the exported file as the connection's identity file.