@ghostystudio/browser-mcp
v0.3.6
Published
MCP server that gives any coding agent (Claude Code, Cursor, Codex…) the user's own Chrome through the Ghosty for Chrome extension — locally via native messaging or remotely via Ghosty Studio.
Maintainers
Readme
@ghostystudio/browser-mcp
MCP server that lends your own Chrome — with the sessions you already have open — to any coding agent (Claude Code, Cursor, Codex, any MCP client), through the Ghosty for Chrome extension. Same idea as Claude in Chrome: the agent reads pages (accessibility snapshot with refs), clicks, types, fills forms, uploads files, takes screenshots and works in several tabs at once. You see a lilac border, a named cursor and a ■ Stop button. It never types passwords.
Setup
Install Ghosty for Chrome: https://www.ghosty.studio/chrome
Local bridge (same computer, no internet, no token):
npx -y @ghostystudio/browser-mcp install-hostReload the extension (
chrome://extensions→ ↻). Its panel says Terminal: connected.Add it to your agent:
claude mcp add ghosty-browser -- npx -y @ghostystudio/browser-mcp # Claude Code codex mcp add ghosty-browser -- npx -y @ghostystudio/browser-mcp # CodexCursor (
~/.cursor/mcp.json):{ "mcpServers": { "ghosty-browser": { "command": "npx", "args": ["-y", "@ghostystudio/browser-mcp"] } } }
Register it once. Your agent starts the server once per session and keeps it alive, so each tool
call costs milliseconds. Don't spawn npx per call (1–2 s each). For scripts, install it globally and
use the call mode:
npm i -g @ghostystudio/browser-mcp
ghosty-browser-mcp call read_page '{"tabId": 123}'Slow tools (over 3 s) send MCP notifications/progress ("click: waiting for the page to react… 5 s")
when the client passes a progressToken; the extension panel shows the same.
Background tabs work: the extension keeps them alive (focus emulation + active lifecycle via CDP)
and captures with Page.captureScreenshot, so it can read, click, type and screenshot tabs you are
not looking at.
Remote (Chrome on another machine): set GS_BROWSER_TOKEN to the bt_… token from the extension panel
(«Connect the terminal») and the calls go through Ghosty Studio.
Tools
browser_status, browser_navigate, browser_read_page, browser_find, browser_click, browser_type,
browser_fill_form, browser_select_option, browser_press_key, browser_hover, browser_drag,
browser_wait_for, browser_get_page_text, browser_take_screenshot, browser_file_upload,
browser_attach_image, browser_tabs, browser_console_messages, browser_network_requests,
browser_computer, browser_handle_dialog, browser_gif_creator, browser_resize… Each MCP process
is its own session (GS_BROWSER_SESSION, a random id by default): the extension gives it its own tab,
so several agents can drive the same Chrome at once without stepping on each other. Every tool also
takes an optional tabId: open more tabs with browser_tabs {action:"new", background:true} to run
several tasks of the same agent in parallel.
When the process exits, its tab is freed right away and closed after 2 minutes, so tabs don't pile up.
browser_batch {actions:[{name, input}, …]} runs several tools in ONE call, in order (navigate, type,
click, wait, read): one model round trip instead of many, and only the last step returns a snapshot.
It stops at the first error, pending confirmation, captcha, dialog, or a stale ref after the page
changed — after navigating, target with a selector or text.
Native dialogs (confirm/alert/prompt/beforeunload) are dismissed by default and reported
in the action's answer; call browser_handle_dialog {accept:true} before the action to accept the
next one, or on one left open. No tool hangs on an open dialog.
Env: GS_BROWSER_TOKEN, GS_URL (default https://www.ghosty.studio), GHOSTY_BROWSER_VIA=native|gs,
GS_BROWSER_CLIENT (name shown in the panel). Docs: https://www.ghosty.studio/docs/navegador
