Codeman logocodeman GitHub →

Use Claude Code from your phone without a laggy SSH app

Updated 2026-09-25

On this pageWhy a phone SSH session feels badOption 1: Anthropic's Remote Control (Claude Code only)Option 2: SSH, tmux and moshOption 3: a terminal in the browserHow Codeman handles it

Run Claude Code on a computer that stays on, inside tmux, and reach it from your phone over a private network. The lag you feel in a phone SSH app is remote echo: every character travels to the server and back before it appears, so the fix is a client that paints your keystrokes locally plus a connection that survives network changes.

Why a phone SSH session feels bad

Three separate problems stack up:

Every option below fixes some of these. Pick by which ones bother you.

Option 1: Anthropic's Remote Control (Claude Code only)

Claude Code has a built-in way to continue a local session from the Claude app on iOS or Android, or from claude.ai/code. Start a session with it enabled:

claude --remote-control

or run /remote-control inside a session that is already open. Claude keeps running on your machine, and the phone becomes another front end to the same conversation. According to Anthropic's docs, it is available on all plans (on Team and Enterprise an Owner has to enable it first), and if your laptop sleeps or the network drops, Claude Code reconnects when the machine comes back online.

This is the least setup if you only use Claude Code and like the app's interface. The session still runs on your machine, so that machine has to be awake for work to continue.

Option 2: SSH, tmux and mosh

This works for any CLI, not only Claude Code. On the machine that will do the work:

tmux new -s claude     # then start claude inside it
# detach with Ctrl-b d; claude keeps running

From the phone, attach with any SSH client (Termius and Blink are common choices):

ssh you@your-box -t tmux attach -t claude

tmux fixes the dropped-connection problem: the session belongs to the tmux server, not to your SSH connection, so you reattach where you left off.

Mosh fixes the echo problem. It gives "an instant response to typing, deleting, and line editing", roams between networks, and keeps the connection through sleep. It needs UDP ports 60000 to 61000 open on the server, and it syncs only the visible screen, which is why its own docs recommend tmux or screen on the remote side for scrollback:

mosh you@your-box -- tmux attach -t claude

To reach a home machine without opening ports to the internet, put both devices on a private network such as Tailscale and connect to the machine's tailnet name.

If you use Claude Code inside tmux regularly, Anthropic's terminal configuration page lists three ~/.tmux.conf lines (allow-passthrough and extended keys) that let notifications reach your outer terminal and make Shift+Enter insert a newline.

What this option does not fix: typing a long prompt on a phone keyboard into a TUI is still awkward, and nothing tells you which session needs you unless you check.

Option 3: a terminal in the browser

The third approach runs the agents in tmux on the server and streams the real terminal to a web page. A web page can add what a plain SSH client lacks: touch controls sized for a phone, several sessions in tabs, and web push notifications, while the terminal itself stays real.

How Codeman handles it

Codeman is that third approach: a self-hosted dashboard that runs Claude Code, Codex, Gemini CLI and other agent CLIs in tmux sessions and streams them to any browser. Install it on the machine that does the work:

curl -fsSL https://getcodeman.com/install | bash

Reaching it. Codeman binds 127.0.0.1 by default, so nothing is exposed until you choose to. The recommended route is Tailscale: the installer can install it, enable tailnet HTTPS and run tailscale serve, which gives you https://<machine>.<tailnet>.ts.net with a real certificate on every device in your tailnet. A Cloudflare tunnel with a password is the alternative when you need a public URL. Remote Access covers both, plus the security trade-offs.

Logging in. With a password set, the desktop dashboard shows a QR code. Each code is single use and rotates every 60 seconds, and the desktop shows which device just logged in with a one-click revoke, so you never type a long password on a phone keyboard.

Typing without lag. On touch devices, Codeman paints keystrokes in the terminal immediately and sends them when you press Enter, instead of waiting for each character to round-trip. The consequence to remember: text on screen has not reached the agent until you press Enter (or the toolbar's Enter button). Codex sessions use a predictive echo instead, because Codex reacts to every keystroke. Input is delivered exactly once, so a connection that drops mid-prompt neither loses the prompt nor sends it twice.

Phone controls. A key bar above the keyboard carries /init, /clear, /compact, Esc and a Compose key that opens a multiline editor. Shell sessions get Ctrl, Esc, Tab and arrow keys instead. You swipe the terminal to switch sessions, and the home screen lists sessions that need you first.

Knowing when to look. Web push reaches the phone with no tab open. It needs HTTPS, and on iOS Codeman has to be added to the home screen first. See Get notified when Claude Code finishes.

If you prefer an SSH client after all, codeman tui gives a terminal dashboard of the same sessions that collapses to a single column under 72 columns wide.

The full phone walkthrough is in the Mobile Guide.