Dev.to AI πŸ€– Ai πŸ‘ 0 πŸ“– 2 min read

Give Claude Code a real cloud browser in 2 minutes (MCP)

Disclosure: I work on Browsa, the cloud browser used here. The MCP server is open source (MIT). Claude Code can drive a local headless browser, but that browser runs on your machine, forgets every login when it closes,

Disclosure: I work on Browsa, the cloud browser used here. The MCP server is open source (MIT).

Claude Code can drive a local headless browser, but that browser runs on your machine, forgets every login when it closes, and announces itself as HeadlessChrome. This post connects Claude Code to a cloud browser over MCP instead. It takes one command.

1. Get a key

Sign up at app.browsa.io (100 free credits after email verification, no card) and create an API key. It starts with agt_live_.

2. Add the MCP server

claude mcp add browsa -e BROWSA_API_KEY=agt_live_... -- npx -y @browsa/mcp
claude mcp list

It needs Node.js 18 or later. Cursor, VS Code and Claude Desktop take the same server in their JSON config; see the MCP setup guide.

3. Ask for something

I gave Claude Code this prompt:

Open news.ycombinator.com in a Browsa browser, find the highest-ranked Show HN post that links to GitHub, and give me its title, points and repo URL as JSON.

49 seconds later it answered:

{
  "title": "Show HN: Type-C – variants, options, generics and pattern matching for C",
  "points": 36,
  "repo_url": "https://github.com/stass/type-c"
}

What I liked is what came with it. The front page had only one Show HN post, and it linked to a website, not GitHub. So Claude went to the Show HN page, took the highest-ranked post there that links to GitHub, and said so. It also pointed out that a lower-ranked post had more points (357), in case that was what I meant. Then it closed the browser so it would stop using credits.

That run cost 3 credits on the Browsa side (balance before and after). That's about 30 cents on the smallest pack.

What it costs

  • A browser: 1 credit per started 12 minutes it runs.
  • An agent task (run_task): its browser time, plus 1 credit, plus 1 per 5 steps. A 10-step task inside 12 minutes is 4 credits with your own model key, 9 on Browsa's hosted model.
  • Credits never expire, there is no subscription, and a failed task gets its browser charge back.

Going further

  • Keep logins between runs with a persistent identity: cookies and storage survive across sessions.
  • Watch it work: every browser has a live view link.
  • Same browser from code: the next post in this series drives it from Playwright by changing one line.

Source for the MCP server and the Python and TypeScript SDKs: github.com/browsa-io/browsa.

πŸ“° Read the original article on Dev.to AI

Originally published by Dev.to AI. Aggregated on AIWithGhost for educational purposes β€” full credit and traffic to the original publisher.