How-to guide
Run CC Babysitter on a server
On a Linux server you reach over SSH, CC Babysitter keeps Claude Code sessions running when SSH drops. It starts them again after a reboot or if they stop. You reach them from your phone or from any terminal.
Before you start
- A Linux server you reach over SSH, where your login has a systemd user manager:
systemctl --user statusanswers. - Claude Code 2.1.275 or later on the server, logged in with your claude.ai account, which Remote Control needs.
Install it
Over SSH, run:
On a machine with no display, the script also sets CC Babysitter up as a service of your user. It starts at boot and keeps running after you log out. At the end, the script prints a command to reach the page from your laptop.
If it says loginctl enable-linger failed, run the sudo command it prints, so the service keeps running after you log out. If it only prints "Start it with", your login has no systemd user manager, and CC Babysitter can't run as a service there.
Open the page from your laptop
The page only listens on the server itself, so you reach it through SSH. On your laptop, run the command the script printed. It looks like this, with your own user and server, and the port may differ:
ssh -L 47391:127.0.0.1:47391 you@your-server
While that connection is open, open the address the script printed, which starts with 127.0.0.1 and ends with the page's key, in your browser. The window stays an ordinary shell on the server.
To see the ssh command again, run ccbabysitter open on the server, and for the address, ccbabysitter status. On a cloud server, the printed command can contain the server's private address. Use the address you normally SSH to instead.
Start a session
On the page, press New session, type the full path of a project folder on the server, and press Start. CC Babysitter starts Claude Code there in the background, with Remote Control, and babysits it. From the server's shell, the same is:
Claude Code runs only in a folder it trusts. The first time you use a folder, the page shows Claude Code's question about it, and Trust and start answers Yes for you. The command says so instead and starts nothing; run it again with --trust. Claude Code records the trust itself. Your home folder can't be used, so choose a project folder.
You can also start a session yourself, in a project folder on the server:
CC Babysitter babysits it as soon as it starts. If you'd rather choose each time for sessions you start this way, switch off Babysit every new background session in Settings, or run ccbabysitter settings auto-babysit off. Then press Babysit on the sessions you want kept alive, including any that were already running when you installed CC Babysitter.
Leave and come back
Close SSH. The session keeps running, and if the server restarts, CC Babysitter starts it again in the background.
To reach it, open the Claude app on your phone and find it among your Claude Code sessions. To work in it from a terminal, its card on the page has two commands with Copy buttons:
- Attach is
claude attachwith the session's short id, to run in an SSH shell on the server. - From elsewhere is the same command run over SSH, to paste into a terminal on your laptop.
Closing that terminal only detaches it. The session keeps running.
When you're done
Unbabysit stops the babysitting and leaves the session running as an ordinary background session. To end it, press Stop background copy. If CC Babysitter brought it back after a restart, choose End background copy from the card's menu instead. Either way the conversation is kept, and its row under Not running has the command to resume it.
From a shell on the server, the same two are ccbabysitter unbabysit and ccbabysitter stop with the session's id.