How to Use Claude Code Remote-Control From Your Phone to Access Your Mac
I wanted to work on my projects from my phone. Not just view files or check logs - I wanted to actually run Claude Code sessions. Every solution I found involved setting up Telegram bots, configuring Tailscale, or dealing with SSH tunneling and port forwarding. All of them felt like security nightmares waiting to happen.
Then I discovered Claude Code has a built-in feature for this exact use case.
The Problem
Claude Code is incredibly powerful for development work, but I’m not always at my desk. Sometimes I’m on the couch, at a coffee shop, or just away from my Mac. I wanted to:
- Start new Claude Code sessions from my phone
- Continue working on existing projects
- Do this without exposing my machine to the internet
- Avoid setting up complex networking infrastructure
Most solutions I found online suggested Telegram bots or Tailscale. While those work, they require:
- Creating and managing bot tokens
- Configuring VPNs and network routing
- Keeping track of connection strings
- Worrying about security implications
I kept thinking there had to be a simpler way.
Discovery: Built-in Remote Control
While digging through Claude Code’s documentation, I found the remote-control command. It’s a native feature that does exactly what I needed - and it works through Anthropic’s servers over HTTPS. No exposed ports, no VPN configuration, no bot tokens to manage.
Here’s how it works:
Step 1: Enable Remote Control
First, I needed to enable the feature in Claude Code’s configuration. I ran:
claudeInside Claude Code, I opened the config:
/configThis brought up the configuration menu. I navigated to the remote control settings and enabled it. The exact steps vary by version, but it’s straightforward - just toggle it on.
Step 2: Start the Remote-Control Server
The key insight is that remote-control should be run as a standalone process, NOT during an active session. This was my first mistake - I initially tried running it while Claude Code was already active, which doesn’t work correctly.
I exited Claude Code and ran:
claude remote-controlThis starts a persistent server that listens for connections from the Claude mobile app. The server runs in the foreground, so I typically run it in a tmux session or as a background service.
To verify it’s running:
lsof -i :8765Or check the process:
ps aux | grep claudeStep 3: Create a Launchd Service (Optional but Recommended)
For always-on availability, I created a launchd service. This ensures the remote-control server starts automatically and restarts if it crashes.
First, I created the service definition:
<?xml version="1.0" encoding="UTF-8"?><!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd"><plist version="1.0"><dict> <key>Label</key> <string>com.claude.remote-control</string> <key>ProgramArguments</key> <array> <string>/usr/local/bin/claude</string> <string>remote-control</string> </array> <key>RunAtLoad</key> <true/> <key>KeepAlive</key> <true/> <key>StandardOutPath</key> <string>/tmp/claude-remote-control.log</string> <key>StandardErrorPath</key> <string>/tmp/claude-remote-control.err</string></dict></plist>Then loaded it:
launchctl load ~/Library/LaunchAgents/com.claude.remote-control.plistTo check status:
launchctl list | grep claudeStep 4: Connect From Your Phone
I opened the Claude app on my iPhone (the Android app works the same way). Under the Claude Code tab, my Mac appeared automatically. No manual pairing required - it just showed up.
I tapped it and could immediately start a new Claude Code session. The interface is clean and responsive. I could:
- Start new conversations
- Work on my projects
- Run commands
- Review and edit code
The connection goes through Anthropic’s servers over HTTPS, which means:
- No firewall configuration needed
- No exposed ports on my home network
- Encrypted traffic
- Works from anywhere with internet access
Common Mistakes I Made
Running remote-control Inside a Session
My first attempt failed because I ran claude remote-control while already inside a Claude Code session. It needs to run as a standalone process. Exit Claude Code completely first, then run the command.
Not Enabling Remote Control in Config
I spent 20 minutes trying to connect before realizing I hadn’t enabled the feature in /config. Make sure this is toggled on before starting the server.
Expecting Session Persistence
Each connection from the phone starts a NEW session. It doesn’t reconnect to an existing session on the Mac. This is actually a security feature - sessions are isolated and don’t persist state unexpectedly.
Permission Popups
The first time I started remote-control, macOS asked for various permissions (network access, etc.). I initially dismissed these and wondered why connections failed. Grant the permissions when prompted.
Why This Matters
Simplicity: One command. No bots, no VPNs, no network configuration. It just works.
Security: All traffic goes through Anthropic’s HTTPS endpoints. My Mac isn’t directly exposed to the internet. No open ports, no port forwarding, no firewall rules to manage.
Accessibility: As long as my Mac is on and the remote-control server is running, I can connect from anywhere. Coffee shop, office, traveling - doesn’t matter.
Persistence: With the launchd service, it’s always available. If the process crashes, it restarts automatically. If I reboot my Mac, it starts on login.
Native Integration: This isn’t a third-party hack. It’s built into Claude Code and designed to work seamlessly with the official mobile apps.
Verification and Troubleshooting
If connections fail, I check a few things:
# Check if the service is listeningnetstat -an | grep 8765
# Check launchd service statuslaunchctl list | grep claude
# View logs if using launchdtail -f /tmp/claude-remote-control.logThe most common issue is the server not running. After that, check your internet connection and ensure remote-control is enabled in Claude Code’s config.
What I Use This For
Since setting this up, I’ve used it for:
- Quick code reviews while away from my desk
- Starting long-running tasks before I get home
- Debugging issues remotely without full SSH access
- Continuing conversations about projects from my phone
It’s become an essential part of my workflow. The ability to tap into Claude Code from anywhere, without security concerns or complex setup, is genuinely useful.
Final Words + More Resources
My intention with this article was to help others share my knowledge and experience. If you want to contact me, you can contact by email: Email me
Here are also the most important links from this article along with some further resources that will help you in this scope:
Oh, and if you found these resources useful, don’t forget to support me by starring the repo on GitHub!
Comments