Claude Code can drive a real browser, but a browser on your laptop is hard to share, hard to watch, and hard to clean up. neu-browser-mcp gives Claude Code a remote browser it can create, drive over CDP, and delete, with a live view you can open to watch or take over.
This tutorial uses the Kernel backend, which needs only an API key. It gives you live view, file listing, and file reads. Download links are not available on Kernel.
1. Requirements
- Node.js 22 or newer
- Claude Code
- A Kernel API key (
KERNEL_API_KEY) - agent-browser, for the browser control step (see its README for install)
2. Add the server to Claude Code
claude mcp add browser \
--env NEU_BROWSER_BACKEND=kernel \
--env KERNEL_API_KEY=<your-key> \
-- npx -y neu-browser-mcp
The key stays in the server's environment. The agent never sees it.
3. Ask for a browser
Start Claude Code and ask:
Create a browser, open https://example.com with agent-browser, and tell me the page title.
Claude Code calls create_browser, which returns a browser_id, a connect_command, and a live_view_url. It then runs the connect_command and reads the page.
4. Watch it, or take over
Open live_view_url in your own browser. You see what the agent sees. Click into the page to take over, then hand control back by telling Claude Code to continue.
5. Read what it downloaded
If the page produces a file, ask:
List the files in the browser and read the first one.
list_browser_files and read_browser_file cover this. Reads are capped at 256 KB.
6. Clean up
Delete the browser.
delete_browser stops it. Idle browsers also end at the backend's timeout (one hour by default on Kernel).
What this does not do
- It does not click, type, or navigate. The agent drives the browser with agent-browser, Playwright, or any CDP client.
- Other backends (
nap,browser-use,hyperbrowser) have different capabilities. The table in the README lists them.
Top comments (1)
tr.ee/dev-to