# Run Pane on a Cloud VM

import { Callout } from "nextra/components";

Want agents that keep working while your laptop sleeps? Run Pane's host on a VM. The VM runs the agents, terminals and git worktrees. Your laptop or phone just shows them.

<Callout type="info">
  Pane doesn't create or pay for cloud machines. You make the VM with any provider and run Pane on it as a [Remote Pane](/docs/remote-daemon) host. Earlier versions had a built-in "Cloud Workspaces" feature. It's gone, because this does the same job and works more reliably.
</Callout>

<RemoteArchitecture />

## Set it up

1. Create an Ubuntu 24.04 VM with any provider. Size it for the agents and builds you'll run. It only needs inbound SSH. Pane's host listens on the VM itself, and you reach it through Tailscale or an SSH tunnel.
2. SSH in as a regular user with `sudo`, not as `root`.
3. Install what your agents need on the VM: `git`, Node.js 20 or newer, and the agent CLIs you use, like Claude Code or Codex. Sign in to each one on the VM. The agents run there, not on your laptop.
4. Install Tailscale and join your tailnet:

   ```bash
   curl -fsSL https://tailscale.com/install.sh | sh
   sudo tailscale up
   ```

5. Install Pane and get a connection code. `--format deb` installs the Debian package, so the VM doesn't need FUSE:

   ```bash
   npx --yes runpane@latest install daemon --label "Cloud VM" --format deb
   ```

6. Make sure the host keeps running after you log out. Setup usually handles this. If it says it couldn't, run:

   ```bash
   sudo loginctl enable-linger "$USER"
   systemctl --user status pane-remote-daemon.service
   ```

7. Copy the `pane-remote://...` code it prints.

## Connect

1. Open **Settings > Remote Access > Remote Pane** in desktop Pane, or open [runpane.com/app](https://runpane.com/app/) in a browser.
2. Paste the code into the **Connection Code** field.
3. Click **Import & Connect**.

Your VM's projects show up in the sidebar once you're connected.

## Host status

**Settings > Remote Access > Remote Pane** on the VM shows:

- **Remote host live** (green dot): the VM is accepting connections.
- **Paired clients**: every device that imported a connection code.
- **Stop Remote Host**: shuts the host down and disconnects everyone.

You can also set the **Machine Label** and **Listen Port**, and choose how clients connect: Tailscale (recommended), SSH Tunnel, or Manual HTTPS.

## Starting and stopping the VM

Use your provider's console or CLI. When the VM stops, its agents stop too. Your repos, worktrees and agent configs stay on the VM's disk as long as you keep the disk.

Something not working? Run `npx --yes runpane@latest doctor --json` on the VM, then check [Troubleshooting](/docs/troubleshooting).

For the difference between files, layouts and running processes, read [What is session persistence?](/what-is-session-persistence) and the [Pane glossary](/glossary).
