TellWorldAI World Archive
Ask中文

Home›Practice›Practice

Practice

Running Claude Code tasks in the cloud

Claude Code on the web runs tasks in cloud VMs that keep going after you close your laptop. Learn to start tasks from the terminal, pull sessions back, share them, and auto-fix pull requests.

Who this is for and what you will get

Cloud sessions suit a batch of fairly independent tasks, such as a few bug fixes or a set of tests, or work you want Claude to continue after you step away from your computer. By the end you will be able to start a cloud task from the terminal, run several at once, pull a session back to your machine, and know when another approach fits better.[1]

What a cloud session is

A cloud session is a Claude Code session that runs on cloud infrastructure instead of on your machine. It persists even if you close your laptop.[1] You can start one from claude.ai/code in a browser, from the Code tab of the Claude mobile app, from the Desktop app, from the terminal with claude --cloud, or through cloud scheduled tasks.[1] Pro, Max, Ultra and Team plans include the feature. Enterprise users need premium seats or Chat + Claude Code seats.[1]

Each session runs in a cloud environment, which controls network access, environment variables and setup scripts. The first-run onboarding creates a Default environment with Limited network access.[1]

Connect GitHub

Cloud sessions need to clone code and push branches. You can install the Claude GitHub App on a repository, or run /web-setup in your terminal to send your local gh CLI token to your Claude account.[1]

In Anthropic-hosted environments, GitHub credentials stay encrypted on Anthropic's servers and never enter a session's VM. GitHub operations from the VM go through a proxy that attaches the credential on the server side.[1]

Start a task from the terminal

Pass the task to --cloud:

claude --cloud "Fix the authentication bug in src/auth/login.ts"

This creates a new cloud session on claude.ai. The cloud VM clones the GitHub remote of the current directory at your current branch, not your local checkout, so push any local commits first.[1] The task runs in the cloud while you keep working locally.[1]

For a complex task, agree on a plan before handing the work over. Start in plan mode:

claude --permission-mode plan

In plan mode, Claude reads files, runs commands to explore, and proposes a plan without editing source code.[1]

Several tasks can run at once, because each --cloud command creates its own independent session:

claude --cloud "Fix the flaky test in auth.spec.ts"
claude --cloud "Update the API documentation"
claude --cloud "Refactor the logger to use structured output"

When the repository is not on GitHub

If you run claude --cloud in a repository with no git remote, or in a github.com repository without the Claude GitHub App installed, Claude Code bundles the local repository and uploads it to the session. This happens even when you have connected GitHub with /web-setup.[1] A full clone's bundle contains the history of all branches and the uncommitted changes to tracked files.[1] On macOS, Linux and WSL, uncommitted changes to credential and key files, such as .env, Terraform *.tfvars, id_rsa and *.pem, stay out of the upload.[1]

To force an upload even when Claude Code could clone from the remote, set CCR_FORCE_BUNDLE=1:

CCR_FORCE_BUNDLE=1 claude --cloud "Run the test suite and fix any failures"

A bundle needs a git repository with at least one commit, and it must stay under 100 MB. Untracked files are left out, so run git add on any file the session needs.[1]

Follow up from the command line

You can send a follow-up to a running session from any machine where you are signed in with claude auth login:

claude -p "your message" --cloud <session-id>

The command posts one message and exits without waiting for a reply. It suits following up on a task that is already running.[1] On success it prints the session ID and a link. With --output-format json, the output has the shape below.[1]

Sent to cloud session.
Session ID: session_01HJKLMNOPQRSTUVWXYZ
View: https://claude.ai/code/session_01HJKLMNOPQRSTUVWXYZ?from=cli&m=0

To bring a session back to your terminal, run claude --teleport for a picker or claude --teleport <session-id> for a specific session.[1] Teleport needs a clean git state, a checkout of the same repository (not a fork), a branch that has been pushed to the remote, and the same claude.ai account.[1]

The terminal receives its own copy of the session. Work done there stays local and does not show up in the cloud session. To keep steering from your phone, start /remote-control in the local session.[1] If the cloud session was compacted, the messages it summarized are not copied over, and Claude continues from the summary.[1]

Permissions, sharing and archiving

Choose the permission mode from the mode dropdown when you create the task, or while the session runs.[1]

Visibility depends on the account. Enterprise and Team accounts can choose Private or Team. Max, Ultra and Pro accounts can choose Private or Public, and a Public session is visible to any user signed in to claude.ai.[1] A session may contain code and credentials from private repositories, so review it before you share it.[1]

Archiving removes a session from the sidebar list, and Unarchive brings it back. Deleting removes the session and its data permanently, cannot be undone, and asks for confirmation first.[1]

Auto-fix pull requests

Auto-fix needs the Claude GitHub App on the repository. When a CI check fails or a reviewer comments, Claude investigates. It pushes a fix when the fix is clear, and it asks you first when a comment is ambiguous or touches something architectural.[1] GitHub sends no webhook when the base branch moves and causes a merge conflict, so auto-fix cannot handle that case on its own. Open the session and ask Claude to rebase.[1]

To stop Claude from suggesting plugins, deny the two plugin tools in permissions.deny:

{
  "permissions": {
    "deny": ["SearchPlugins", "SuggestPluginInstall"]
  }
}

Limits and common problems

  • The session stops when idle. After a period of inactivity the VM is reclaimed. Reopening the session restores the conversation, but shell commands and subagents that were running are not restored, so ask Claude to run them again.[1]
  • Parallel tasks use up rate limits faster. Cloud sessions share rate limits with every other Claude and Claude Code use on your account.[1]
  • **Unable to get organization UUID.** This means you are signed in with an API key or Console account. Run claude auth login to sign in with claude.ai.[1]

Next step

To set up tools, network access and setup scripts for the cloud environment, see the cloud environments page in Anthropic's Claude Code documentation.[1]

Sources

  1. 1
    Use Claude Code in the cloudAnthropic Claude Code docs

Cite this page: Running Claude Code tasks in the cloud. TellWorld, https://www.tellworld.net/practice/practice-claude-code-on-the-web. Updated 2026-11-14

Related news

View all