Give OpenAI Codex CLI control of your browser
Codex gets eyes on the running app: real pages, real sessions, real verification.
Last updated: August 2026
In short
Vibe MCP adds browser tools to OpenAI Codex CLI over the Model Context Protocol. Add the @vibebrowser/mcp server to your Codex configuration and Codex can navigate, click, type, scroll, screenshot, and extract content from your real Chrome, including pages that require a login.
The problem
- Codex CLI edits code and runs commands, but has no way to look at the app it just changed.
- A throwaway headless browser cannot reach your staging dashboard, your admin panel, or anything gated behind SSO.
- Building a bespoke browser harness per repo is wasted effort.
What Vibe MCP changes
- One MCP entry and Codex can drive the Chrome you already use, with your logins intact.
- Structured page snapshots keep Codex context small and its actions targeted.
- Two transports, and you pick per machine: the local STDIO server keeps every byte on your machine, or the hosted URL skips the local process entirely. Only one of them is local — see the note on each step.
Set it up in 4 steps
1Install the Vibe extension in Chrome
Add Vibe AI Browser from the Chrome Web Store (Chrome, Brave, Edge, or any Chromium browser). This is the piece that lets an agent drive the browser you are already logged into — no second browser profile, no re-authentication.
2Add Vibe to ~/.codex/config.toml
Codex keeps MCP servers in TOML, not JSON. Append the block below to ~/.codex/config.toml (or a project-scoped .codex/config.toml), then restart Codex. Prefer one command? Run codex mcp add vibe -- npx -y @vibebrowser/mcp and Codex writes the same entry for you. Verify with codex mcp list, or type /mcp inside the TUI.
~/.codex/config.tomltoml[mcp_servers.vibe] command = "npx" args = ["-y", "@vibebrowser/mcp"]3Or point Codex at the hosted connector URL instead (not local)
Codex reads MCP servers from ~/.codex/config.toml, and the ChatGPT desktop app and the Codex IDE extension read that same file — so registering the server once covers all three surfaces. Copy your Agent connection URL from the Vibe icon → Settings → "Enable external AI agent control" → Remote (internet), then run the command below; it writes a [mcp_servers.vibe] table with a url key. Be clear-eyed about the trade: unlike the STDIO step above, this transport is NOT local — tool calls and page content travel through the Vibe relay. The URL contains your routing UUID and is a credential, so keep it out of committed files and screenshots.
terminalbashcodex mcp add vibe --url https://relay.api.vibebrowser.app/mcp/<your-routing-uuid>4Connect the extension and run your first command
Click the Vibe icon, open Settings, and enable "MCP External Control" until the status reads Connected. Then ask your agent to open a page and take a snapshot — it should return the content of your real tab.
Your relay URL / extension UUID grants live control of your browser session. Treat it like a password: never commit it or paste it into a shared chat.
Tools OpenAI Codex CLI gets
| Tool | Description |
|---|---|
| navigate_to_url | Navigate to any URL |
| go_back / go_forward | Browser history navigation |
| click | Click elements on the page |
| type / fill | Enter text into inputs |
| scroll | Scroll the page |
| take_screenshot | Capture screenshots |
| get_page_content | Extract page text or HTML |
| get_tabs / create_new_tab / switch_to_tab / close_tab | Tab management |
| keyboard_shortcut | Press keyboard combinations |
| web_search | Search the web |
How it compares
| Feature | Vibe MCP | Playwright MCP | BrowserMCP |
|---|---|---|---|
| Multi-agent support | Yes | No | No |
| Uses your browser profile | Yes | No | No |
| Logged-in sessions | Yes | No | No |
| No separate browser | Yes | No | No |
| Local & private | Yes | Yes | Partial |
| Content-script based | Yes | No | No |
OpenAI Codex CLI browser control — FAQ
- Can Codex use the hosted relay instead of a local server?
- Yes. Run codex mcp add vibe --url https://relay.api.vibebrowser.app/mcp/<your-routing-uuid> with the routing UUID from the Vibe extension; Codex writes a [mcp_servers.vibe] table with a url key into ~/.codex/config.toml. Because Codex CLI, Codex Desktop and the Codex IDE extension all read that one file, registering it once covers all three — there is no separate in-app connector menu to visit. Note the trade-off: this transport routes through the Vibe relay, so it is not the local path.
- Does OpenAI Codex CLI support MCP servers?
- Yes. Codex loads MCP servers from ~/.codex/config.toml, which is how Vibe adds browser tools. Add a [mcp_servers.vibe] table with command = "npx" and args = ["-y", "@vibebrowser/mcp"], then restart Codex. The config is TOML, not JSON.
- Where is the Codex MCP config file?
- Codex reads ~/.codex/config.toml by default. You can also scope servers to a single trusted project with .codex/config.toml in the repo root. The ChatGPT desktop app, Codex CLI, and the Codex IDE extension all share this same file.
- Can Codex CLI control my real Chrome?
- Yes. With the Vibe extension installed and MCP External Control enabled, Codex drives your existing Chrome profile — same tabs, same cookies, same logged-in sessions.
- Can I run Codex CLI and Claude Code on the browser together?
- Yes. Vibe is built for multi-agent use: a shared relay daemon multiplexes connections so multiple agents can control one browser without conflicts.
- Does my browsing data go to a server?
- No. The MCP server and relay run locally on your machine. Page content goes only to the agent you connected.
Works with your other agents too
The same MCP server powers every client. Multiple agents can drive the same browser at once.
Ready to connect OpenAI Codex CLI?
Connecting an agent to your logged-in browser has real privacy consequences. Read what is transmitted, logged and retained in the Privacy Policy.