Guide #1 Getting Started 20 min read March 2026

Give Claude Code Its Own Machine

Claude Code is the most popular coding agent on the planet — 18.9 million monthly active users, 4% of all GitHub commits, $2.5 billion in run-rate revenue. It's a TUI that runs in a terminal. Right now, that terminal is on your laptop.

This guide gives it a dedicated cloud machine. You SSH into a sandbox, run claude, and it has its own filesystem, its own credentials, its own compute. It persists when you close your laptop. It can run overnight. And you can spin up 10 of them in parallel.

The mental model: the sandbox IS the computer

The wrong way to think about this is "proxy Claude Code's bash calls to a remote API." That's backwards. Claude Code is a TUI — a terminal user interface. It reads files, runs bash, calls git, uses grep. It's designed to run inside a terminal on a real machine.

So give it a real machine. The sandbox IS the machine. You SSH into it, install Claude Code there, run claude, and everything it does happens inside that isolated environment. It has its own filesystem, its own git config, its own package managers, its own processes. It can't see your laptop. Your laptop can't see it.

Your laptop → SSH → Sandbox (Ubuntu VM) Claude Code runs HERE. Full terminal. Full filesystem. Its own machine.

This is the same pattern developers have used for decades — working on a remote server. The difference is the server is API-provisioned, auto-stops when idle, bills by the minute, and you can spin up 10 of them for 10 different tasks.

Why not just use your laptop?

Claude Code on your laptop is great for pair-programming on a feature branch. It stops being great when:

Claude Code on your laptop

  • Agent has your credentials, your files, your everything
  • One machine, shared with Slack, Chrome, and Spotify
  • Dies when you close the lid or lose WiFi
  • Can't run 10 agents in parallel
  • "Works on my machine" environment drift

Claude Code on a sandbox

  • Isolated VM — trash it and spin up a new one
  • Dedicated CPU and RAM, no resource contention
  • Persists across sessions, runs overnight unattended
  • Spin up 10 for 10 tasks, each with its own machine
  • Fresh Ubuntu every time, reproducible by design

Quickstart: Claude Code on a sandbox in 5 minutes

1

Create a sandbox

Use the API or dashboard to provision a ab0t.medium (2 vCPU, 4 GB RAM). This takes about 30 seconds.

bash
# Set your API key
export SANDBOX_API_KEY="ab0t_sk_live_YOUR_KEY_HERE"
export SANDBOX_URL="https://sandbox.dev.ab0t.com"

# Create the sandbox
curl -s -X POST "$SANDBOX_URL/api/sandboxes" \
  -H "Authorization: Bearer $SANDBOX_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "name": "claude-code-dev",
    "instance_type": "ab0t.medium",
    "auto_stop_minutes": 120
  }' | jq .

# Response:
# {
#   "sandbox_id": "sandbox_a1b2c3d4",
#   "status": "pending",
#   "instance_ip": "54.xx.xx.xx",
#   "hourly_cost": "0.04"
# }
2

Upload your SSH key and connect

Upload your public key so you can SSH in, or use a short-lived certificate.

bash
# Upload your SSH key
curl -s -X POST "$SANDBOX_URL/api/ssh-keys" \
  -H "Authorization: Bearer $SANDBOX_API_KEY" \
  -H "Content-Type: application/json" \
  -d "{
    \"name\": \"my-laptop\",
    \"public_key\": \"$(cat ~/.ssh/id_ed25519.pub)\"
  }"

# SSH into the sandbox (once status is "running")
ssh ubuntu@54.xx.xx.xx
3

Install Claude Code on the sandbox

You're now inside the sandbox. Install Claude Code and authenticate.

bash (inside sandbox)
# Install Node.js (Claude Code requires it)
curl -fsSL https://deb.nodesource.com/setup_22.x | sudo -E bash -
sudo apt-get install -y nodejs git

# Install Claude Code
npm install -g @anthropic-ai/claude-code

# Set your Anthropic API key
export ANTHROPIC_API_KEY="sk-ant-YOUR_KEY_HERE"

# Verify it works
claude --version
4

Use Claude Code like normal — but it's on the sandbox

Everything Claude Code does now happens on the sandbox VM. Git clones, pip installs, test runs, file edits — all on isolated cloud compute.

bash (inside sandbox)
# Clone your project
git clone https://github.com/your-org/your-project.git
cd your-project

# Start Claude Code
claude

# Now use Claude Code exactly as you normally would:
> Run the test suite and fix any failures.
> Install whatever dependencies are needed.
> Make a new branch and commit your changes.

# Claude Code runs `pip install`, `pytest`, `git commit` etc.
# All of it happens on the sandbox. Your laptop is free.
That's it.

Claude Code is now running on a dedicated cloud machine. It has its own filesystem, its own packages, its own git config. You can close your terminal, reconnect later, and everything is still there (the sandbox persists). When you're done, stop the sandbox to pause billing.

Automate the setup with a bootstrap script

You'll want to standardize the sandbox environment so every instance starts with Claude Code, your tools, and your config ready to go. Here's a bootstrap script you can pass to the sandbox on creation:

bash — bootstrap-claude-code.sh
#!/bin/bash
# Bootstrap script for Claude Code sandboxes
# Upload this and run it after SSH-ing in, or execute via the API:
#   POST /api/sandboxes/{id}/execute {"command": "bash /workspace/bootstrap.sh"}

set -euo pipefail

echo "=== Installing system packages ==="
sudo apt-get update -qq
sudo apt-get install -y -qq nodejs npm git curl jq ripgrep fd-find tmux

echo "=== Installing Claude Code ==="
sudo npm install -g @anthropic-ai/claude-code

echo "=== Setting up git config ==="
git config --global user.name "Claude Code Agent"
git config --global user.email "agent@your-company.com"
git config --global init.defaultBranch main

echo "=== Creating workspace ==="
mkdir -p /home/ubuntu/workspace
cd /home/ubuntu/workspace

echo "=== Writing CLAUDE.md ==="
cat > CLAUDE.md << 'EOF'
# Agent workspace

You are running on a cloud sandbox (Ubuntu, ab0t.medium).
This is an isolated machine — you have full root access.
Install any packages you need with apt-get or pip or npm.

## Guidelines
- Commit frequently with descriptive messages.
- Run tests after every change.
- If a test suite takes longer than 10 minutes, break it into parallel runs.
- Save important outputs to /home/ubuntu/workspace/output/.
EOF

echo "=== Ready. Run: claude ==="

You can automate this further by using the execute API to run the bootstrap right after sandbox creation — no SSH needed:

bash
# Create sandbox and run bootstrap in one go
SANDBOX=$(curl -s -X POST "$SANDBOX_URL/api/sandboxes" \
  -H "Authorization: Bearer $SANDBOX_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"name":"claude-agent","instance_type":"ab0t.medium","auto_stop_minutes":120}')

SANDBOX_ID=$(echo "$SANDBOX" | jq -r '.sandbox_id')
echo "Created: $SANDBOX_ID — waiting for boot..."
sleep 45

# Run bootstrap
curl -s -X POST "$SANDBOX_URL/api/sandboxes/$SANDBOX_ID/execute" \
  -H "Authorization: Bearer $SANDBOX_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"command": "curl -sL https://your-company.com/bootstrap-claude-code.sh | bash"}' | jq .

echo "Sandbox ready. SSH in with:"
echo "  ssh ubuntu@$(echo $SANDBOX | jq -r '.instance_ip')"

Running multiple agents in parallel

This is where the sandbox model really shines. Want to test your project across three Python versions? Create three sandboxes.

bash
# Create 3 sandboxes, one per Python version
for pyver in 3.10 3.11 3.12; do
    RESULT=$(curl -s -X POST "$SANDBOX_URL/api/sandboxes" \
      -H "Authorization: Bearer $SANDBOX_API_KEY" \
      -H "Content-Type: application/json" \
      -d "{\"name\":\"test-py${pyver}\",\"instance_type\":\"ab0t.small\",\"auto_stop_minutes\":60}")

    SID=$(echo "$RESULT" | jq -r '.sandbox_id')
    echo "Python $pyver sandbox: $SID"
done

# Wait for all to boot, then SSH into each in a separate tmux pane
# and run: claude "Clone myrepo, install Python $VER, run pytest"
# Each agent works independently on its own machine.
#
# Cost: 3 x ab0t.small x 20 min = $0.02 total

Or use Claude Code's Agent Teams feature. With sandboxes already provisioned, the team lead assigns each worker to an SSH session on a different sandbox:

prompt to Claude Code
> I have three sandboxes running:
>   - sandbox_py310 at 54.1.2.3 (Python 3.10)
>   - sandbox_py311 at 54.4.5.6 (Python 3.11)
>   - sandbox_py312 at 54.7.8.9 (Python 3.12)
>
> Use Agent Teams to SSH into each one and run the full test suite
> for github.com/myorg/myproject. Report which tests pass/fail on
> each version. Use the execute API at $SANDBOX_URL/api/sandboxes/{id}/execute
> if SSH isn't available yet.

Run agents overnight

The sandbox persists even when you disconnect. Set a generous auto_stop_minutes (or 0 for never), SSH in, start Claude Code inside tmux, detach, and close your laptop.

bash (inside sandbox)
# Start a tmux session
tmux new -s agent

# Inside tmux: set your key and start Claude Code
export ANTHROPIC_API_KEY="sk-ant-YOUR_KEY"
cd /home/ubuntu/workspace/my-project

# Give it a big task
claude "Refactor the entire authentication module from callbacks to async/await.
Update all call sites. Run the test suite after each file change.
Keep going until all 847 tests pass. Commit each logical change separately.
I'll check the results in the morning."

# Detach from tmux: press Ctrl+B, then D
# Close your laptop. Go to sleep.
# Tomorrow: ssh back in and run `tmux attach -t agent`
Cost for an overnight run

A ab0t.medium running for 8 hours costs $0.32. That's less than a cup of coffee for a full night of autonomous coding. Set auto_stop_minutes: 0 for overnight tasks so the sandbox doesn't idle-stop between Claude Code's thinking pauses.

What to run on sandbox Claude Code

Now that Claude Code has its own machine, here are the tasks that benefit most:

Large refactors

Give it a multi-hour refactoring job. It won't compete with your local dev environment for CPU. It won't die when your laptop sleeps. Let it churn through hundreds of files while you do other work.

Dependency audits

Clone an unfamiliar repo, install its dependencies, and audit what runs during installation. All in a disposable VM — if a postinstall script is malicious, it can't reach your real machine.

Test matrix

Spin up N sandboxes for N configurations. Python versions, Node versions, OS versions, database versions. Each runs the full suite in parallel. Collect results.

PR review with execution

For every PR, spin up a sandbox, checkout the branch, run the tests, check for regressions. Post results as a PR comment. The sandbox dies after the review.

Exploring new codebases

Clone a large open-source project and tell Claude Code to read it, run it, and explain the architecture. All on a sandbox — the project's dependencies don't pollute your machine.

What it costs

TaskInstanceDurationCost
Quick test runab0t.micro~10 min$0.002
Feature development sessionab0t.medium~2 hrs$0.08
Overnight refactorab0t.medium~8 hrs$0.32
3-way test matrix (parallel)3x ab0t.small~20 min each$0.02
Full-day coding with idle gapsab0t.medium, auto-stop~4 hrs active$0.16
GPU ML experimentab0t.gpu~30 min$0.27
Compare to running Devin

Devin charges ~$9/hour ($2.25 per 15-min ACU). A ab0t.medium sandbox costs $0.04/hour and you bring your own model. For a 2-hour coding session, that's $18 with Devin vs $0.08 + your Anthropic API costs with a sandbox.

Tips for production use

Always use tmux or screen

If your SSH connection drops, tmux keeps Claude Code running. Without it, a network blip kills your agent mid-task. Install tmux in your bootstrap script.

Set auto_stop_minutes appropriately

For interactive sessions: 60–120 minutes. For overnight jobs: 0 (never auto-stop). For CI-like tasks: 30 minutes. The #1 cause of unexpected bills is forgetting to stop a sandbox with auto-stop disabled.

Use ab0t.micro for simple tasks

Not every task needs 4 GB of RAM. Linting, formatting, simple test suites, and code review all run fine on a ab0t.micro at $0.01/hr — 4x cheaper than ab0t.medium.

Pre-bake your bootstrap into a custom Docker image

If your team uses the same setup every time (Node + Python + Claude Code + your internal tools), build a Docker image with everything pre-installed. Pass it as docker_image when creating the sandbox. Cold start drops from 2 minutes to 30 seconds.

Set up a CLAUDE.md in your bootstrap

The bootstrap script writes a CLAUDE.md to the workspace. Claude Code reads this automatically. Use it to tell the agent about the sandbox environment, coding standards, and what tools are available.

Troubleshooting

SSH connection refused

The sandbox takes 30–60 seconds to boot. Wait until the status is running (poll GET /api/sandboxes/{id}). Also verify your SSH key was uploaded before the sandbox was created.

Claude Code says "command not found"

The bootstrap script didn't run, or Node.js isn't installed. SSH in and run the bootstrap manually. Check that node --version and claude --version both return output.

Agent runs out of disk space

Default sandboxes have 8 GB of disk. For large repos or ML datasets, use a ab0t.large (16 GB) or ab0t.xlarge (32 GB). Check usage with df -h.

Sandbox stopped unexpectedly

Check auto_stop_minutes. If Claude Code was thinking (not executing commands) for longer than the idle timeout, the sandbox may have stopped. Set a higher timeout or use 0 for long tasks.

Can't authenticate Claude Code inside the sandbox

Set ANTHROPIC_API_KEY as an environment variable inside the sandbox. Add it to your bootstrap script or ~/.bashrc. Don't hardcode it in CLAUDE.md.

What's next

Give your agent its own machine

SSH in. Run claude. Walk away. Isolated, metered, instant.

Get Started Free