Recipes

Always-on Claude Code agent with a persistent real browser, reachable over Telegram

From README links · today

Software & DevOpsWork & Operations

Rent a $5 VPS, run one script, and text a browser-using agent from anywhere.

What they did

They took a fresh $5 Ubuntu VPS and turned it into a always-on personal agent. First they pasted the repo's setup prompt into Claude Code on their laptop, handing it SSH access to the box. Claude read install.md, ran install.sh with a Browser Use Cloud API key, and optionally passed a Telegram bot token from @BotFather so the agent could be texted. After install, they verified the systemd units (bux-browser-keeper and bux-ttyd) were active, switched to the bux user, and completed the claude /login OAuth flow. Finally they smoke-tested by asking the agent to visit browser-use.com and report the page title. The agent runs claude -p behind a Telegram bot and a localhost-bound ttyd web terminal, driving a real Chromium session through browser-harness over CDP to Browser Use Cloud, with state persisted in /home/bux so cookies, skills, and chat history survive reboots.

How it went

The install is idempotent and the smoke test is a single prompt, so a working agent is reachable in well under an hour on a $5 box. Logins persist across reboots, and when the agent hits a login wall, 2FA, or CAPTCHA it hands back a live view URL and waits for a human instead of trying to stuff credentials. Polish is high for the happy path; the managed pilot pages suggest the vendor expects teams to need hand-holding for real workflows.

Worth knowing

You need a Browser Use Cloud API key (free tier: 3 concurrent browsers) plus an Anthropic API key or Claude Max subscription, and optionally a Telegram bot token. The box must be Ubuntu 22.04+ with at least 2GB RAM. The web terminal is bound to localhost, so remote access needs an SSH tunnel. The agent's behavior lives in agent/CLAUDE.md, which you must edit and re-run install.sh to change. Human handoff for 2FA and CAPTCHAs is by design, not a bug, but it means unattended flows can stall.

Wiring

Order: provision an Ubuntu 22.04+ box with >=2GB RAM, get a Browser Use Cloud API key and an Anthropic key or Claude Max login, optionally create a Telegram bot via @BotFather. Run: curl -fsSL https://raw.githubusercontent.com/browser-use/bux/main/install.sh | sudo BROWSER_USE_API_KEY=bu_xxx TG_BOT_TOKEN=xxx bash. The installer creates a bux user and three systemd services: bux-browser-keeper (keeps the Chromium/browser-harness session alive), bux-ttyd (web terminal on localhost), and the Telegram bot. Data flow: telegram_bot.py or ttyd -> claude -p -> browser-harness -> Browser Use Cloud over CDP/wss, with state in /home/bux. After install, run claude /login as bux, then edit agent/CLAUDE.md and re-run install.sh (idempotent) to apply behavior changes.

Try it yourself

Set up https://github.com/browser-use/bux on my remote box. SSH into it (host below), read install.md first, then run install.sh with my BROWSER_USE_API_KEY and my TG_BOT_TOKEN if I provide one. Verify systemctl is-active bux-browser-keeper bux-ttyd, become the bux user, and run claude /login so I can finish OAuth. Then test by asking claude to visit https://browser-use.com and report the page title. Finally, show me agent/CLAUDE.md and suggest edits for my use case.

Source

Tools in this stack

Run this stack

Install the stack into this project. It writes AGENTS.md and the manifest, merges the MCP servers into .mcp.json, and — with --yes — runs the tool installs.

npx runchr install runchr/stack-browser-harness-and-bux
No CLI?curl -s https://api.runchr.com/api/recipes/runchr/stack-browser-harness-and-bux/manifest
System prompt
You are an always-on Claude Code agent running on a VPS, reachable over Telegram and a localhost ttyd terminal, with a real persistent Chromium browser. Drive the browser through browser-harness for any web task, and when you hit a login wall, 2FA, or CAPTCHA, hand back a live view URL and wait for a human instead of attempting to enter credentials.

This system prompt was generated from this stack's copy and tools. A person has not reviewed it.

The manifest is also at api.runchr.com/api/recipes/runchr/stack-browser-harness-and-bux/manifest.