← Back to blog
AiAbout 6 min read

Your agent can finally open the browser's real devtools, telemetry included

Published Nov 29, 2026
Your agent can finally open the browser's real devtools, telemetry included

Ask an agent to fix a slow page and watch what it does. It reads the source, guesses at the cause, edits something plausible, and declares victory. Nothing in that loop ever measured the page. The agent has been debugging with its eyes closed and a confident vocabulary.

chrome-devtools-mcp is Google's answer to that, and it has picked up 59,780 stars doing it. It is an MCP server, plus a CLI, that gives a coding agent control of a live Chrome instance: record a performance trace and get back the insights, inspect network requests, read console messages with source-mapped stack traces, take screenshots, and drive clicks through puppeteer with automatic waiting for the result.

The install is the standard MCP ritual:

{
  "mcpServers": {
    "chrome-devtools": {
      "command": "npx",
      "args": ["-y", "chrome-devtools-mcp@latest"]
    }
  }
}

Then the first prompt in the docs: check the performance of https://developers.chrome.com. The server starts the browser on the first tool call that needs one, so connecting alone does not launch anything.

The part that changes the loop

A performance trace is the difference between "this might be causing layout thrash" and "here is the 340 ms task that blocks the main thread on every scroll."

Until now an agent could get that data only if a human recorded it and pasted the JSON, or if the agent wrote a Playwright script that captured a trace and then parsed it blind. Both routes end with the model reasoning about numbers it cannot reproduce.

With the MCP surface, the trace becomes a tool call with a structured response. The agent records, reads the insight list, forms a hypothesis, edits the code, records again, compares. That is the same loop a frontend engineer runs, minus the person.

The same applies to console errors. A stack trace mapped back through a bundler's source maps turns "TypeError: cannot read property of undefined" into a file and line in the original TypeScript. Agents are notoriously bad at acting on minified stacks, which is one reason they tend to rewrite a component instead of fixing a null check.

Seven skills, one product

The package ships more than a server: seven Agent Skills that teach a model how to use it, covering general debugging and automation, the CLI, accessibility auditing, cookies and sessions, Largest Contentful Paint optimization, memory leaks, and connection troubleshooting.

That last one is more revealing than it looks. Troubleshooting a broken MCP-to-Chrome connection is a task that a model would otherwise attack by reinstalling things. Encoding it as a skill means the knowledge lives next to the tool instead of in a support thread.

There is also a CLI for people who want the same control without MCP in the middle:

npm i chrome-devtools-mcp@latest -g
chrome-devtools navigate_page 1 --url "https://developers.chrome.com"
chrome-devtools take_screenshot 1 --filePath screenshot.png
chrome-devtools stop

And a --slim flag that exposes a reduced tool set for basic browsing, which is worth knowing about. Every tool in the list costs context. A server that advertises forty tools will spend a chunk of the window before the agent does anything useful.

The fine print is the story

Three disclosures in the README deserve more attention than the feature list.

First, usage statistics are on by default. Google collects tool invocation success rates, latency and environment information, and you opt out with --no-usage-statistics, or by setting CHROME_DEVTOOLS_MCP_NO_USAGE_STATISTICS or CI. The README is explicit that this is separate from Chrome's own metrics: turning off one does not turn off the other.

Second, the performance tools may send trace URLs to the CrUX API to pull field data alongside lab data. That is a reasonable design, since lab numbers and real-user numbers answer different questions, but it means a URL from your staging environment can leave the machine during a performance audit. --no-performance-crux disables it.

Third, the disclaimer is blunt: the server exposes the content of the browser instance to the MCP client, which can inspect, debug and modify any data in that browser. If you point this at your logged-in Chrome profile, you have handed an agent your sessions. The --isolated flag and a separate user-data directory exist for exactly this reason, and they are the difference between a demo and an incident.

None of this is scandalous. It is the normal shape of a Google developer tool: excellent instrumentation, telemetry defaults that assume you will read the docs. Worth reading them.

What a trace costs

The reason to care about --slim is arithmetic. A performance trace is a timeline of every task, layout, paint and network event, far larger than a screenshot, and the insight extraction is what makes it usable. Even compressed into insights, it is a large object, and an agent that loads three traces in a row has spent a meaningful fraction of its context before writing a line of code.

So the sensible pattern is the one a human uses: record once, read the headline insight, fix the biggest item, record again, compare. Not "collect everything and reason about it."

The CLI is better for that loop than the MCP server in one specific way. You can script it, diff two runs, and keep the output in a file instead of a conversation. If you are doing a performance investigation with a fixed set of pages, driving the CLI from a shell script and handing the agent a summary is cheaper than letting it call tools interactively.

There is also a connect-to-existing-browser mode, which lets you attach to a Chrome instance you started yourself rather than letting the server launch one. That is how you debug something behind a login without exporting cookies, and it is also how you accidentally give an agent a session you did not intend to share. Both outcomes are one flag apart.

Why Google shipped this at all

The strategic read is straightforward. If agents are going to write and verify web code, the browser becomes the runtime they need to observe. Whoever owns the observation layer owns a lot of the feedback loop.

That is also why the repository recommends building on it. The docs point product teams at the Gemini CLI browser agent as a reference implementation for a browser subagent. Google is shipping a debugging tool and also offering the substrate for anyone building agentic browser products, in the hope that the ecosystem standardizes on its DevTools.

The alternative is every agent vendor shipping a worse, private version of the same thing. That has been the pattern for the last two years, and it produces agents that can click but cannot explain why the page got slower.

Practical advice

Two things to do before pointing this at real work.

Scope the browser. Use --isolated or a dedicated profile. An agent with your cookies is an agent with your accounts.

Budget the context. Start with --slim and add tools when the task demands them. A trace is a lot of tokens, and an agent that fills its window with network logs has nothing left for the fix.

Then run the obvious experiment. Ask your agent to make a page faster, and check whether it records a trace before it edits anything. If it still guesses, the tool is installed and the habit is not.

Turn ideas into images with ChatPicture

60 free credits every day. Generate, edit, and download — no prompt engineering degree required.

Related articles