ai-browser-bridge
macOS CLI that drives ChatGPT, Gemini, Claude, and other web chats in Chrome, with sandboxed repo tools over MCP.
Install / Use
claude mcp add YosefHayim -- npx -y github:YosefHayim/ai-browser-bridgeIf the server publishes to npm under a different name, use that package instead — check the repo README.
MCP Server
Model Context Protocol server
Quality Score
Category
AutomationSupported Platforms
Our assessment of ai-browser-bridge
ai-browser-bridge scores 81/100 on our quality scale, 2335th of 2,790 Automation skills we index.
Its MCP Server is 28 KB long, well organised into 24 sections with 23 code examples: a thorough specification that gives an agent plenty to work with.
It has 10 GitHub stars, so there is little community track record yet; judge it on its content.
Maintenance, license and trust
- The repository was last updated yesterday, so ai-browser-bridge is actively maintained.
- It is released under the MIT license, a permissive license that allows use, modification and commercial use with attribution.
- Its trust signals score 97/100, with no cautions. These come from repository metadata, not a code audit — read the skill file before letting an agent act on it.
Safety scan
No issues foundOur scan of the whole file found no instruction hijacking, hidden characters, credential access, data exfiltration or destructive commands. An AI review of the same text found nothing harmful.
AI review by kimi-k2.7-code on 2026-11-15. Automated pattern scan on 2026-11-15. It catches known dangerous patterns, not every risk — read a skill before letting an agent act on it.
ai-browser-bridge compared with similar skills
All 4 of these similar skills score higher than ai-browser-bridge; compare them before choosing.
| Skill | Score | Stars | Updated | Format |
|---|---|---|---|---|
| ai-browser-bridge (this skill)by YosefHayim | 81 | 10 | 1d ago | MCP Server |
| Agent-Reachby Panniantong | 100 | 112.3k | 8d ago | CLAUDE.md |
| rufloby ruvnet | 100 | 81.9k | today | CLAUDE.md |
| headroomby headroomlabs-ai | 100 | 79.8k | today | CLAUDE.md |
| CowAgentby zhayujie | 100 | 48.0k | today | CLAUDE.md |
Frequently asked questions
- How do I install ai-browser-bridge?
- Run
claude mcp add YosefHayim -- npx -y github:YosefHayim/ai-browser-bridge. The install tabs above show the steps for each supported agent. - Which AI agents does ai-browser-bridge work with?
- It is written for Claude Code, Claude Desktop and Gemini CLI, as a MCP Server file. Other agents that read the same format can often use it too.
- Is ai-browser-bridge safe to use?
- Our scan of the whole file found no instruction hijacking, hidden characters, credential access, data exfiltration or destructive commands. An AI review of the same text found nothing harmful. It is MIT-licensed and scores 97/100 on trust signals. Skills are instructions an agent will follow, so read the file before installing it and do not approve commands you do not understand.
- Is ai-browser-bridge still maintained?
- The repository was last updated yesterday, so ai-browser-bridge is actively maintained.
Skill content
View source on GitHubai-browser-bridge
Drive a real ChatGPT or Gemini browser conversation from your terminal, and give ChatGPT a narrow, sandboxed set of local repo tools over MCP — without ever handing it a shell.
English · עברית · Español · 中文
Why this exists
ChatGPT is at its best in the browser — real account state, the model picker, message editing, regeneration, and conversation history all intact. Coding is at its best in the terminal, where files, tests, diffs, and patches are inspected and changed directly.
ai-browser-bridge connects those two surfaces. A terminal prompt drives your existing ChatGPT or Gemini browser session, and ChatGPT can reach into the current repo through a small set of validated MCP tools — grep, read, apply_patch, run_tests, git_diff — instead of raw shell access. You stay in one terminal workflow; the provider keeps its real UI.
Features
- Terminal-driven ChatGPT — send prompts and stream replies without leaving the shell; the real browser conversation stays the source of truth.
- Nine providers, one command —
chatgpt,gemini,claude,deepseek,grok,perplexity,duck(Duck.ai),arena(Arena — Direct/Battle/Agent/Side-by-Side + model picker), plusflow(Google's Veo video studio — a generation surface, not a chat). Pick one with--provider, or fan out across several (--provider claude,deepseek,duck) and get every reply keyed by provider in one call. - Built for agents — a stable non-interactive
bridge ask … --jsoncontract (never hangs in a pipe) plus an outbound MCPasktool, so any agent can drive a web chat. - Sandboxed local tools over MCP — every file operation is validated against the selected repo root; no arbitrary shell, allowlisted test commands only.
- Browser actions as commands —
/resume,/new,/model,/rewind,/stop,/context,/diff,/compact, and more. - Repo-root sessions, transcripts, and downloads — TUI and tool-enabled runs persist under the Git working-tree root's
<repo>/.bridge/, even when launched from a nested directory; plainbridge askstays stateless and only reuses the shared Chrome profile. - Safety controls — permission modes (
read-only/ask/auto) and automatic file checkpoints around every patch. - Project conventions — custom commands plus
AGENTS.md/CLAUDE.mdare fed to ChatGPT for/taskruns. - A real composer — prompt history, reverse search, queued prompts, and
@filemention autocomplete.
Architecture
terminal (you)
│
│ Ink / React CLI
▼
orchestrator ──────────────┬───────────────────────────────┐
│ browser automation │ MCP server │
▼ (Playwright + CDP) │ (MCP SDK) ▼
ChatGPT browser UI │ local repo tools
▲ │ (grep/read/patch/test/diff)
│ ▼ │
└───── Cloudflare Tunnel (cloudflared) ◄────────────────┘
public https://…trycloudflare.com/mcp
Four layers, each with one job:
| Layer | Tech | Responsibility |
| -------------- | ------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| CLI | Ink / React | Terminal UI: message pane, status line, @file mentions, /commands. |
| Browser | Playwright + Chrome DevTools Protocol | Attaches to Chrome on the debug port and reuses one shared bridge Chrome profile. Lifecycle/status/cache code lives in src/browser/; provider selectors live under src/providers/<name>/. |
| MCP server | MCP SDK + zod | Exposes the local repo tools to ChatGPT, Claude, and Grok as schema-validated, sandboxed handlers. |
| Tunnel | Cloudflare Tunnel (cloudflared) | Gives the local MCP server a temporary public HTTPS URL that provider connectors can reach — no deployment required. |
Why a tunnel at all? Provider MCP connectors call tools over HTTPS, but the tool server runs on your machine. Rather than deploy anything, the bridge spins up an ephemeral Cloudflare Tunnel (*.trycloudflare.com) in front of the local port and syncs that Streamable HTTP …/mcp URL into the provider app on startup. (ngrok would solve the same reachability problem; Cloudflare's cloudflared is used because its quick tunnels need no account or auth token. Grok's UI may show an /sse example — the bridge registers /mcp because cloudflared quick tunnels do not support SSE.)
Quick start
Prerequisites
- macOS — Chrome is launched with the macOS
opencommand, and clipboard/process helpers usepbcopy/lsof. - Node.js ≥ 22 and pnpm (the repo pins
pnpm@10.14.0). - Google Chrome or Chrome for Testing — the bridge drives one shared bridge profile through a debug port. Sign in once in that bridge-launched window; every repo reuses it.
cloudflared(optional; ChatGPT, Claude, Grok) — only needed for those providers to call local MCP tools. Without it the TUI still runs. Install withbrew install cloudflared.
Install & build
git clone https://github.com/YosefHayim/ai-browser-bridge.git
cd ai-browser-bridge
pnpm install
pnpm build
Start Chrome, then run (ChatGPT — default)
node dist/bridge.js chrome start
node dist/bridge.js --repo /path/to/your/project
node dist/bridge.js --debug-port 9223 --profile /path/to/chrome-profile
Start Chrome, then run (Gemini web)
node dist/bridge.js chrome start --provider gemini
node dist/bridge.js --provider gemini --repo /path/to/your/project
Install the published CLI with npm install -g ai-browser-bridge; it also installs SKILL.md. From a source checkout, run pnpm build && pnpm link --global to get the bridge command, then use bridge, bridge chrome start, bridge ask "…", etc.
Browser profile policy
Chrome 136+ no longer accepts remote debugging switches against the real default Chrome data directory. ai-browser-bridge therefore never launches Chrome on ~/Library/Application Support/Google/Chrome. By default it launches the browser on the debug port with one global bridge profile:
~/.ai-browser-bridge/chrome-profile
That profile is the browser-login SSOT for the bridge. Sign in once in the bridge-launched Chrome window, then bridge chrome start, bridge ask, and the TUI reuse that login from any repo or shell root.
For release and automation work, Chrome's team recommends Chrome for Testing. Install it separately, then point the bridge at that app while keeping the same shared profile:
AI_BROWSER_BRIDGE_CHROME_APP="Google Chrome for Testing" bridge chrome start
The app override changes only which Chrome build is launched. The profile remains ~/.ai-browser-bridge/chrome-profile; do not add per-repo Chrome profiles. See Chrome's remote-debugging profile change for the upstream reason.
Use your own Chrome instead. Chrome 144+ can share your everyday Chrome with local tools: open chrome://inspect/#remote-debugging and turn remote debugging on (Chrome guide). Then choose it:
export AI_BROWSER_BRIDGE_BROWSER=my-chrome
The bridge then never launches or quits Chrome. Each command connects to your running Chrome, opens its own tab, and closes that tab when it ends; it never types into a tab you opened. Chrome asks you to click Allow each time a command connects. bridge stop only ever closes a Chrome the bridge launched, and fan-out tasks with isolate still use their own isolated profile.
One-shot, non-interactive
node dist/bridge.js ask "summarize @src/core/engine.ts" --repo /path/to/project
node dist/bridge.js ask "hello" --provider gemini --repo /path/to/project
Usage
/help list commands /sessions list local sessions
/resume <query> resume by number/title/id /transcript print the session transcript
/new start a new conversation /export export transcript (md/json/jsonl)
/model [name] show or switch the model /permissions show or switch MCP permission mode
/rewind [text] edit last prompt + regen /checkpoints list file checkpoints
/stop stop the active response /restore <id> restore files from a checkpoint
/context model-aware context est. /status repo/model/context/session status
/diff ask ChatGPT to read diff /mcp connector + exposed tools
/task <request> project-agent task (MCP) /connector (re)run MCP connector setup
/conversations list/search/open browser conversations
File mentions — reference repo files inline; they are resolved inside the repo and expanded before ChatGPT sees them:
refactor the CLI input flow in @src/terminal/tui/shell/app.tsx
compare @src/store/file-mentions.ts with @src/store/file-mentions.test.ts
Paths that escape the repo root are skipped; files over 100 KB are summarized rather than inlined.
Conversation search — bridge chat search "query" --json opens ChatGPT's Search UI,
selects Chats, and returns matching Conversations across titles and message content. It scrolls
the result overlay up to --limit; add --open to navigate the browser to the best match.
Rate-safe Project organization — prepare one ordered plan with Conversations for any number of Projects (Conversation ids are preferred because they can be verified exactly):
[
{ "conversation": "11111111-1111-4111-8111-111111111111", "project": "Yoga App" },
{ "conversation": "22222222-2222-4222-8222-222222222222", "project": "Invoices & Purchases" }
]
Then validate it and start the autonomous queue:
bridge chat organize --plan @organization-plan.json --dry-run
bridge chat organize --plan @organization-plan.json \
--interval 60 --cooldown 600 --max-attempts 4
# No plan argument is needed after the queue exists
bridge chat organize status
bridge chat organize pause
bridge chat organize resume
The queue verifies every move from ChatGPT's loaded Project label, with the destination Project page
as a fallback. Adaptive pacing starts from --interval 60 with jitter. After three successful moves
it reduces the base interval by 20%, down to `--min-interval 1
Truncated for display — read the full file on GitHub.
Related Skills
Agent-Reach
112.3kGive your AI agent eyes to see the entire internet. Read & search Twitter, Reddit, YouTube, GitHub, Bilibili, XiaoHongShu — one CLI, zero API fees.
ruflo
81.9k🌊 The original agent harness. Deploy intelligent multi-player swarms, coordinate autonomous workflows, and build conversational AI systems. Features adaptive memory, self-learning intelligence, federation, vector RAG integration, and native Claude Code / Codex / Hermes and many more Integrated
headroom
79.8kCompress tool outputs, logs, files, and RAG chunks before they reach the LLM. 20% fewer tokens for coding agents, 60-95% fewer tokens for JSON, same answers. Library, proxy, MCP server.
CowAgent
48.0kOpen-source personal AI assistant & Agent Harness. Plans tasks, runs tools and skills, self-evolves with memory and knowledge. Multi-agent, multi-model, multi-channel. Lightweight, extensible, one-line install.
Languages
Trust signals
From repository metadata: license, adoption, age and documentation. Not a code audit — see the Safety scan above for what the skill file itself contains.
