chrome-remote-debugging-mcp
v0.2.1MCP server for controlling Chrome over the DevTools Protocol (CDP).
These tools were reported by the server itself during our smoke test (tools/list), not copied from the README.
ping
Check connectivity to Chrome's DevTools endpoint (``CDP_URL``, or the autoConnect source with ``CHROME_AUTOCONNECT``). Returns ``{"connected": True, "cdp_url", "browser", "protocol"}`` when Chrome answers, or ``{"connected": False, "cdp_url", "error": ...}`` when it is unreachable.
list_tabs
List open Chrome page tabs. Returns ``{"tabs": [{id, title, url, type}, ...]}`` or ``{"error": ...}`` if Chrome is unreachable.
evaluate
Evaluate a short JavaScript ``expression`` in a Chrome tab. Only for small snippets (a few lines): for a longer script, write it to a file and run it with ``evaluate_file`` instead. Awaits promises and returns the value by value. Returns ``{"tab_id", "value", "type"}`` on success, or ``{"error": ...}`` on failure or an uncaught JS exception. A promise that does not settle within 30 s is reported as an error. For a large value (e.g. a page's text) pass ``output_path``: an absolute path (``~`` is expanded) on the machine running this server. The value is written…
| Parameter | Type | Description |
|---|---|---|
expression * | string | |
tab_id * | string | |
output_path |
evaluate_file
Evaluate a JavaScript file in a Chrome tab — ``evaluate`` for big scripts. ``path`` must be absolute (``~`` is expanded) and names a UTF-8 file on the machine running this server, not the one running Chrome. Its contents run exactly as an ``evaluate`` expression: the value of the last statement is returned, promises are awaited (30 s limit), and stack traces of a JS exception name the file. Returns ``{"tab_id", "value", "type"}`` or ``{"error": ...}``. ``output_path`` saves the value to a file instead, exactly as in ``evaluate``.
| Parameter | Type | Description |
|---|---|---|
path * | string | |
tab_id * | string | |
output_path |
cdp_command
Send a raw CDP command and return its raw result — escape hatch. Use when the higher-level tools don't cover what you need. ``method`` is any CDP method (e.g. ``"Page.captureScreenshot"``, ``"DOM.getDocument"``, ``"Network.enable"``); ``params`` are its parameters. Runs in the given tab's persistent session, so ``objectId``/``nodeId`` values and domain state (e.g. ``Network.enable``) carry over between calls while the tab is open and the connection lives. Events are not delivered. So ``Fetch.enable``, ``Debugger.pause``, ``Target.setAutoAttach {waitForDebugg…
| Parameter | Type | Description |
|---|---|---|
method * | string | |
tab_id * | string | |
params |
browse
Open ``url`` and return a readable view of the page, with numbered refs. The view is built from Chrome's accessibility tree — what a screen reader would announce — not from HTML, so it is compact enough to act on. Every interactive element gets a ``#N`` ref usable with ``browse_act``. Opens a new tab when ``tab_id`` is omitted; pass the returned ``tab_id`` to ``browse_act`` / ``browse_view``. Returns ``{"tab_id", "url", "view", "refs"}`` or ``{"error": ...}``.
| Parameter | Type | Description |
|---|---|---|
url * | string | |
tab_id |
browse_view
Re-read the current page and return a fresh view with fresh refs. Refs from an earlier view stop being valid once this returns. Returns ``{"tab_id", "view", "refs"}`` or ``{"error": ...}``.
| Parameter | Type | Description |
|---|---|---|
tab_id * | string |
browse_act
Run several actions against the current view, then return one new view. Each action is a dict with a ``do`` key: - ``{"do": "click", "ref": 3}`` - ``{"do": "type", "ref": 2, "text": "коты", "clear": false}`` - ``{"do": "press", "key": "Enter"}`` - ``{"do": "select", "ref": 5, "value": "два"}`` - ``{"do": "check", "ref": 9}`` / ``{"do": "uncheck", "ref": 9}`` - ``{"do": "scroll", "ref": 7}`` or ``{"do": "scroll", "to": "bottom"}`` - ``{"do": "hover", "ref": 4}`` - ``{"do": "wait_for", "text": "Результаты", "timeout": 5}`` or ``{"do":…
| Parameter | Type | Description |
|---|---|---|
actions_list * | array | |
tab_id * | string |
close_tab
Close a Chrome tab opened earlier (e.g. by ``browse`` / ``navigate``). Its refs are dropped along with it. Returns ``{"tab_id", "closed": True}`` or ``{"error": ...}``.
| Parameter | Type | Description |
|---|---|---|
tab_id * | string |