dia-mcp
This server does not currently have a deployable release on Glama. Follow the repository's setup instructions to install and configure it for your MCP client, including any required credentials and local dependencies.
dia mcp
Dia Browser MCP server. Let an AI agent use the Dia browser you already have open: your tabs, your logins, your session. No debug port, no restart, no second browser.
dia-mcp is the Dia equivalent of chrome-devtools-mcp. It exposes the Chrome DevTools
Protocol of a live Dia tab over MCP, so any agent client (Claude Desktop, Cursor, Hermes,
VS Code) can read pages, click, type, inspect network traffic and console errors, and take
screenshots. Built with FastMCP.
Also searched for as: Dia MCP, Dia Browser MCP, Dia MCP DevTools, Dia MCP server, Dia DevTools MCP.
your agent → mcp_server.py → bridge.py (127.0.0.1:9777) → Dia extension → chrome.debugger → your tabThe browser is never launched or restarted. Dia stays exactly as it is.
Requirements
System | macOS (Dia is macOS only) |
Browser | Dia 1.56 or newer, already open |
Python | 3.10 or newer, plus |
Agent | any MCP client: Hermes, Claude Desktop, Cursor, VS Code, Codex |
Related MCP server: Chrome DevTools MCP
Setup
Three steps, about two minutes.
0. Install FastMCP
python3 -m pip install fastmcpThe bridge itself has no dependencies; only the MCP server needs FastMCP.
1. Start the bridge
python3 tools/bridge.py serveLeave it running. This is the local channel between the extension and your agent. If you skip it, the MCP server starts it for you on first use.
2. Add the extension to Dia
Open Dia and go to
chrome://extensionsTurn on Developer mode in the top right corner
Click Load unpacked
Choose the
extensionfolder inside this repo
One time step. Dia keeps it after a restart.
3. Connect your agent
Hermes:
hermes mcp add dia-mcp \
--command "$(which python3)" \
--args "$(pwd)/mcp_server.py"Then run /reload-mcp in a session, or start a new one.
Any other MCP client, add this and replace the path:
{
"mcpServers": {
"dia-mcp": {
"command": "python3",
"args": ["/absolute/path/to/mcp_server.py"]
}
}
}Check that it works
Ask your agent: "call list_pages and tell me the page ids". You should see the tabs that are open right now.
Or test the bridge directly:
python3 tools/selftest.pyIt prints one line per check and ends with 18/18 checks passed.
Tools
The names and arguments are the same as chrome-devtools-mcp, so instructions and prompts
written for that server work here unchanged. Pages are addressed by pageId and elements by
uid from take_snapshot, exactly as there.
Pages
Tool | What it does |
| Open pages as |
| Open a URL in a new tab and select it |
| Close a page |
| Make a page current; also focuses the tab |
| Navigate, back, forward, or reload |
Inspection
Tool | What it does |
| Elements with |
| CSS rules that apply to a |
Interaction
Tool | What it does |
| Click a |
| Type into an input, textarea, or contenteditable |
| Fill several fields at once |
| Move the mouse over a |
| Drag one |
| Key or combination, for example |
| Type into whatever has focus |
| Attach a local file to a file input |
| Accept or dismiss a JS dialog |
| Wait until text appears |
Network and console
Tool | What it does |
| Requests with status, type, size, URL |
| One request with headers and response body |
| Console output and JS errors |
| One message in full |
Emulation and capture
Tool | What it does |
| Network, CPU, geolocation, user agent, media, viewport, headers |
| Viewport size (emulated, because Dia rejects window resizing) |
| Page, |
| Run a function in the page and return the value |
Present for parity, unavailable on Dia (each fails with a clear message)
Tool | Why |
| Lighthouse needs to drive its own browser |
| tracing needs browser-level events the extension cannot reach |
| continuous frame streaming |
| heap profiler chunks (this also fails on Dia via chrome-devtools-mcp) |
Extras beyond chrome-devtools-mcp
Tool | What it does |
| Attachment state, buffered traffic, page map |
| Disconnect and clear the debug banner |
| Raw CDP command escape hatch |
dia mcp vs Chrome DevTools MCP
chrome-devtools-mcp is the official Chrome server. It is excellent, and on most tasks it is
the right tool. The difference is where it gets its browser.
chrome-devtools-mcp | dia-mcp | |
Browser it controls | Chrome, launched by the server | The Dia window you already have open |
Setup cost | none, it starts its own instance | one |
Your existing tabs and logins | no, unless you relaunch with | yes, immediately |
Restart required | yes, for your own session | never |
Headless | yes | no, Dia is a GUI app |
Several tabs at once | yes, routed by page id | one tab at a time |
What dia mcp does the same
Same tool names, same arguments, same pageId and uid semantics. The differences are
under the hood:
chrome-devtools-mcp | dia-mcp | |
Page addressing |
|
|
Element addressing |
|
|
Snapshot shape | indented accessibility tree | flat |
Click and typing | synthesised input events |
|
One-shot HTTP calls |
| same, with the body included |
Failures | tool error |
|
What dia mcp does not do
Every unavailable tool still exists in the list and fails with an explicit reason, so an agent that expects the full surface gets a clear answer instead of a missing tool.
Missing | Why | Workaround |
Launch or own a browser | Dia cannot take a debug flag without a restart | use |
| Lighthouse needs to drive its own browser instance | run Lighthouse in Chrome |
| tracing needs browser-level events the extension cannot reach | the DevTools Performance panel |
| continuous frame streaming |
|
| heap profiler chunks; this also fails on Dia through chrome-devtools-mcp | the DevTools Memory panel |
Parallel work on many tabs | one | act on one page, then |
| the protocol forbids it | none |
Working while DevTools is open on the tab | one debugger per tab | close DevTools on that tab |
What about chrome-devtools-mcp pointed at Dia?
It mostly works. Launch Dia once with --remote-debugging-port=9222, then run that server
with --browserUrl http://127.0.0.1:9222. In testing on Dia 1.56, 28 of its 32 tools worked.
resize_page and take_heapsnapshot failed, and background tabs behave oddly until they are
focused. The catch is the flag: Dia ignores it when the browser is already running, so your
session has to be closed and reopened. If you are fine with that, that route gives you more
tools. If you want to attach to the browser you are in, use this repo.
FAQ
Is this a fork of chrome-devtools-mcp?
No. It is a small MCP server built with FastMCP, a local bridge, and a browser extension. It
uses the same underlying protocol, chrome.debugger.
Does it need --remote-debugging-port?
No. That flag only works at launch. Dia accepts the request through an extension instead, so
no restart is needed.
Can it see sites I am logged into?
Yes, that is the point, and the trade-off. The agent only reaches the tab you attach to, and
only while the bridge is running. Call dia_detach, or stop the bridge, when you are done.
Does it work with Claude Desktop, Cursor, or Hermes? Yes. It is a plain stdio MCP server, so any client that speaks MCP can run it.
Windows or Linux? No. Dia is macOS only.
Why does a call time out on a tab I am not looking at? Dia freezes background tabs, so timers and requests stall there. Every page tool focuses the tab first. If you still see a timeout, the extension is not loaded, or the repo moved after it was loaded.
What is in this repo
Path | Role |
| The Dia extension. Drives one tab at a time through |
| Local bridge, also usable from a terminal as |
| FastMCP server your agent connects to; starts the bridge if needed |
| The one Python dependency: |
| 18 live checks against your own browser |
| Instructions for an AI agent to do this setup for you |
License
MIT. Use it, change it, ship it, sell it. Keep the copyright notice with the code.
This server cannot be deployed
Maintenance
Related MCP Connectors
Give AI agents a real cloud Chrome: open sessions, navigate, read pages, click, type and screenshot.
Live browser debugging for AI assistants — DOM, console, network via MCP.
Control a real browser from AI agents: navigate, click, type, screenshot, read the page.
Cloud browser, web extraction, screenshots, and remote CDP tools for AI agents.
Related MCP Servers
- AlicenseNot gradedqualityAmaintenanceEnables AI coding assistants to control and inspect a live Chrome browser through Chrome DevTools. Provides browser automation, performance analysis, debugging capabilities, and network request monitoring.1,876,272 npm54,821Apache 2.0
- AlicenseAqualityCmaintenanceEnables AI coding assistants to control and inspect a live Chrome browser for automation, debugging, performance analysis, and screenshot capture through Chrome DevTools.261,876,272 npm3Apache 2.0
- AlicenseNot gradedqualityDmaintenanceEnables AI coding assistants to control and inspect a live Chrome browser for automation, debugging, performance analysis, network monitoring, and DOM interaction through Chrome DevTools Protocol.1,876,272 npmApache 2.0
- AlicenseNot gradedqualityDmaintenanceEnables AI coding assistants to control and inspect a live Chrome browser through Chrome DevTools for automation, debugging, and performance analysis.1,876,272 npmApache 2.0