Onepilot
← Back to blog

April 5, 2026 · 4 min read

Claude Code on iPhone: How to Run It in 2026

Claude Code is Anthropic's agentic coding tool — it reads your codebase, runs commands, edits files, and commits code. It's built for the terminal. Which means you can run it from anywhere you have an SSH connection — including your iPhone.

What You Need

  • An iPhone with Onepilot installed (free)
  • A server with SSH access (any provider)
  • A Claude Code subscription (Anthropic Max plan) or API key

Step 1: Set Up Your Server

If Claude Code isn't installed on your server yet, SSH in from Onepilot and install it:

npm install -g @anthropic-ai/claude-code

Authenticate with your Anthropic account or set your API key as an environment variable.

Step 2: Connect from Your iPhone

Open Onepilot, add your server (hostname, username, SSH key or password), and connect. You get a full VT100 terminal — Claude Code's interactive UI renders natively.

Step 3: Start Claude Code

Navigate to your project directory and run:

claude

Claude Code launches in interactive mode. You see the same interface as on a desktop terminal — file diffs, command execution, tool calls — all rendered on your phone screen.

Step 4: Give It a Task

Type your task in natural language:

  • "Fix the failing CI tests in the payments module"
  • "Add rate limiting to the API endpoints"
  • "Refactor the database queries to use connection pooling"

Claude Code reads the relevant files, proposes changes, and executes them after your approval.

Tips for iPhone

  • Use headless mode for long tasks — claude -p "your task here" runs without interactive prompts
  • Pair with tmux or screen — detach the session, close the app, reconnect later to check progress
  • Start big tasks before idle time — commute, lunch, overnight — let the agent work while you're away

Why Not Just Use a Laptop?

You absolutely can. But laptops aren't always available. Claude Code on mobile isn't about replacing your desk setup — it's about never being blocked. Incident at 2 AM, idea on the train, quick fix between meetings. Your phone is always there.

Wondering how Claude Code stacks up against Codex? Read our Codex vs Claude Code comparison. Or start from scratch with our SSH from iPhone guide.

Try Onepilot — Free

Mobile SSH & AI agent deployment from your iPhone.

Get Started