Claude Code hands a browser task to the OpenAI Codex desktop app and reads the answer back on its own. Two strong models working together. No more being the copy-paste in the middle.
A Claude Code skill that turns "go verify this in the browser" into something Claude can pass to Codex and pick the result back up automatically.
Claude Code can drive a browser really well. I use it all the time. But every now and then it stops short on something it's completely capable of doing. Usually it's a task that touches a login or a password, or something it decides is too privacy-sensitive to go near. I get why it's careful. It still leaves me stuck.
Here's the thing: Codex doesn't stop. Point it at the browser and it just does the job.
So for a while my "solution" was to play messenger. Claude would write up the browser task, I'd copy it into the Codex desktop app, Codex would run it in Chrome, then I'd copy the result back into Claude so it could keep going. It worked. But I was the slow part. I'd literally sit there moving text between two AIs that are both better at this than I am.
And the fix? I used Codex itself to build a little bridge that does the handoff for me. Now Claude sends the browser task straight to the Codex app and reads the answer back on its own. Nobody in the middle.
I'm a big believer in getting two strong models to work together instead of betting everything on one. I once ran an agent for five days straight where Claude Code and Codex had to agree on the plan before either wrote a line of code, then both had to sign off before anything counted as done. It built the whole app while I mostly watched. This skill is that same idea pointed at Chrome. Claude is the brain running the show. Codex is the one with its hands on the browser.
Once you have that, a lot opens up. You can have it confirm a website actually works. You can have it review a design. You can hand it a full QA pass on a web app and let it click through every screen. I've gotten so much use out of this that I wanted to put it out there for everyone.
The Codex desktop app and the Codex CLI both write every session to ~/.codex/sessions/… as a rollout log. The bridge uses that:
- It opens a fresh chat in the Codex desktop app and pastes your task (through macOS System Events).
- It tags the task with a unique id so it can find exactly the right session.
- It tails that session's log until Codex finishes, then prints Codex's final answer to stdout. Claude reads that and keeps going.
Claude Code ──(prompt)──▶ Codex desktop app ──▶ Chrome
▲ │
└──────────(final answer, auto)────────────────┘
Now for the annoying part. This should just work from the Codex CLI with no desktop app at all. It doesn't. Right now a CLI-started session can't grab the Chrome backend, so you get Browser is not available: chrome, while the desktop app on the same machine does it fine. It's a known bug, tracked at openai/codex#26820.
I tested this every way I could think of before I gave up on the CLI, including talking to a CLI-spawned app-server directly over its own protocol. Same wall every time. So the bridge drives the Codex desktop app instead, because that's the version that can actually control Chrome.
If you run Claude Code as your main harness like I do, this is the only way I've found to get Claude and Codex doing browser work together today. My hope is the Codex team fixes the CLI so any agent from any harness can drive the browser without the app open. The day that lands, you can throw this away and swap in a plain codex exec call. Until then, this is how you do it.
- macOS. The bridge runs on AppleScript and System Events.
- Claude Code as your agent.
- The Codex desktop app, installed, running, and signed in, with its Chrome extension set up and working.
- Node.js.
- Accessibility permission for your terminal app, under System Settings, Privacy & Security, Accessibility. That's what lets it drive the Codex app.
git clone https://github.com/humanrouter/codex-browser-skill.git
mkdir -p ~/.claude/skills/codex-desktop
cp -R codex-browser-skill/SKILL.md codex-browser-skill/scripts ~/.claude/skills/codex-desktop/Then in Claude Code, just tell it to "have Codex do X in the browser" and it'll pick up the skill.
You don't need Claude to use this. You can run the bridge on its own:
node ~/.claude/skills/codex-desktop/scripts/codex-app-task.mjs \
--prompt "Using your Chrome browser control plugin, go to example.com and report the page title." \
--timeout 300It prints SESSION: <rollout file>, then ANSWER:, then whatever Codex came back with.
Flags
| Flag | What it does |
|---|---|
--prompt "..." |
The task. Write it self-contained. Codex has none of Claude's context. |
--prompt-file <path> |
Read the prompt from a file, handy for long tasks. |
--timeout <seconds> |
How long to wait for Codex to finish. Default is 900. |
--no-refocus |
Skip trying to return focus to your previous app. |
Exit codes: 0 all good. 2 the prompt never reached a Codex session, so the send failed. 3 Codex didn't finish before the timeout, though it keeps running in the app, so check the session file it printed. 4 bad arguments or an AppleScript failure.
When the bridge fires, it pulls the Codex app to the front for a second to paste your task, then tries to hand focus back to whatever you were working in. That hand-back is best effort. It depends on macOS and on what your app calls its own process under the hood.
For most apps it just works. Some don't cooperate out of the box. I use Warp. Its process is named stable instead of Warp, which throws off the obvious approach. If your app doesn't get focus back, you've got two easy fixes. Run it with --no-refocus and skip the whole thing. Or open scripts/codex-app-task.mjs and set your app or process name directly in the short refocus block near the bottom.
The default tries to do the right thing. Treat it as a starting point, not a promise for every setup.
- The Codex app runs your task with whatever approval settings you've got. Mine runs unattended with no prompts, so the bridge does too. If yours is the same, write your prompts read-only unless you actually want it changing things.
- It uses the clipboard to paste. It puts your old clipboard text back a few seconds later.
- Keep the Codex app open. If it's closed, run
open -a Codexand give it a few seconds before you fire the bridge.
MIT © 2026 Thanh Pham (Human Router)