Playwright MCP and Chrome DevTools MCP both give a coding agent a real browser to check its work in. Playwright MCP, from Microsoft, drives the page through its accessibility tree: it reads the page as a list of headings, links and buttons, each with a reference the agent can click. That makes it the better default for walking through a flow and confirming it works. Chrome DevTools MCP, from Google’s Chrome team, also drives Chrome, but it brings what DevTools knows: performance traces, Lighthouse audits, and network and console detail. Reach for it when the question is “why is this slow?” or “what does Lighthouse think?”. There’s also a third option, Claude in Chrome, for when the agent needs your own signed-in browser. Each one takes a single command to add to Claude Code.
I wanted to know how they differ in practice, not in their READMEs, so I ran both against a small checkout page with a bug in it and against one of my own posts. Below is what each one saw, what it cost in context, and which I’d install.
This is also where the conversation about coding agents went in November. How the Claude Code team thinks about verification (292 points on Hacker News) says that if you invest in one kind of test, make it end-to-end, and give the agent “hands and eyes on the real running system”. On Zenn, a developer who has stopped reading most of Claude Code’s pull requests described what they check instead: acceptance criteria, and a sub-agent that clicks through the staging site without reading the code. And GeekNews picked up Reticle, a tool built around an agent pressing the buttons and reading the network log after it changes something. Browser access is how an agent proves a UI change works without you opening the page yourself.
Install Playwright MCP and Chrome DevTools MCP in Claude Code#
Both are npm packages that Claude Code starts on demand over stdio. Add them to a project like this:
claude mcp add --scope project playwright -- npx @playwright/mcp@latest
claude mcp add --scope project chrome-devtools -- npx chrome-devtools-mcp@latest--scope project writes them to .mcp.json in the repository, so everyone who clones it gets the same browser tools. Claude Code asks each person to approve a project’s servers the first time, which is why claude mcp list shows them as pending until you start claude. Use --scope user instead if you want them in every project on your machine. Chrome DevTools MCP’s own instructions use that.
A few flags worth knowing before you start:
- Playwright MCP opens a visible browser window by default. Add
--headlessif you don’t want to watch, and--isolatedto keep the browser profile in memory rather than on disk. - Chrome DevTools MCP sends usage statistics to Google by default. Turn that off with
--no-usage-statistics. Its performance tools can also send the traced URL to Google’s CrUX API to fetch real-user data;--no-performance-cruxstops that. Both are in its README. - Chrome DevTools MCP officially supports only Google Chrome and Chrome for Testing. I don’t have Chrome on this Mac, just Edge, so I pointed both servers at the Chrome for Testing build Playwright had already downloaded:
--executable-pathfor Playwright MCP,--executablePathfor Chrome DevTools MCP. - Chrome DevTools MCP also comes as a Claude Code plugin, with skills for LCP, accessibility and memory leaks. Install it with
/plugin marketplace add ChromeDevTools/chrome-devtools-mcpand then/plugin install chrome-devtools-mcp@chrome-devtools-plugins.
How the two compare#
These are the versions I tested on 19 November: Playwright MCP 0.0.86 and Chrome DevTools MCP 1.13.0. I listed their tools by connecting to each one directly from a short Python script.
| Playwright MCP | Chrome DevTools MCP | Claude in Chrome | |
|---|---|---|---|
| Made by | Microsoft | Google’s Chrome DevTools team | Anthropic |
| Browser | Chromium, Chrome, Edge, Firefox or WebKit | Chrome (other Chromium browsers may work, unsupported) | Your own Chrome, Edge or other Chromium browser, signed in |
| Tools | 25 | 33 (3 with --slim) | Built into Claude Code with --chrome |
| How it sees the page | Accessibility snapshot in YAML, with ref ids to click | Accessibility snapshot as text, with uids to click | Reads the page in your browser |
| Extras | Shows the Playwright code behind every action; can attach to your running browser through an extension (--extension) | Performance traces, Lighthouse, computed CSS, heap snapshots, screencasts | Your logins and cookies, GIF recording |
| Best for | Clicking through a flow and checking the result | Speed, Lighthouse, deep network and console work | Anything behind a login |
The test: a checkout button that does nothing#
The demo is one HTML page: a small “Your order” card with a Place order button. On load it fetches /api/cart, which returns 404 because, in the story, the endpoint was renamed. An empty .catch() swallows the failure, so clicking the button throws TypeError: Cannot read properties of undefined (reading 'items') and nothing appears. I also gave the promo line white-space: nowrap, so it runs out of the card. That second bug doesn’t throw anything; it’s purely visual.
I drove each server myself first: navigate, take a snapshot, click the button, read the console and the network log. Their snapshots of the card are close to identical. Playwright’s:
- main [ref=e2]:
- heading "Your order" [level=1] [ref=e3]
- generic [ref=e10]:
- generic [ref=e11]: Total
- generic [ref=e12]: $19.50
- paragraph [ref=e13]: Free shipping on every order over $50 this week only, use code FREESHIPPINGNOVEMBER at checkout
- button "Place order" [ref=e14] [cursor=pointer]
- status [ref=e15]Chrome DevTools MCP’s:
uid=1_0 RootWebArea "myapp · Checkout" url="http://127.0.0.1:8765/"
uid=1_1 main
uid=1_2 heading "Your order" level="1"
uid=1_7 "Total"
uid=1_8 "$19.50"
uid=1_9 "Free shipping on every order over $50 this week only, use code FREESHIPPINGNOVEMBER at checkout"
uid=1_10 button "Place order"
uid=1_11 status atomic live="polite" relevant="additions text"Both caught the real bug. After the click, Playwright MCP’s console tool returned the TypeError with its stack position (:34:31) and both 404s, one for the cart and one for a missing favicon. Chrome DevTools MCP listed the same errors, folded the two 404s into one line marked “[2 times]”, and can add source-mapped stack traces when asked. Each network tool showed GET /api/cart [404].
Neither snapshot can see the overflowing promo line. To the accessibility tree it’s a paragraph with the right words in it. The screenshot is the only place it shows:

Then I let Claude Code do the job, once with each server, using a prompt that said only “The Place order button does nothing. Use the browser tools to find out why, and check the page for anything else that looks broken. Don’t edit any files.” Both runs took about 23 seconds and 12 turns, and claude -p reported about US$0.21 each at API prices. Both found the 404, the swallowed error and the TypeError. Both took a screenshot without being asked and reported the overflowing promo line too. The Playwright run measured it (665 px of text in a 420 px card); the DevTools run named the CSS rule. On a page this small there was no winner. The difference shows up in what each one costs and in what else it can measure.
What it costs in context#
Two numbers matter here.
The tool definitions are 22.3 KB for Playwright MCP’s 25 tools and 33.8 KB for Chrome DevTools MCP’s 33. In older setups that whole schema sat in the context window from the first message. Claude Code now defers MCP tool definitions by default: only the names load at the start, and a definition arrives when the agent goes looking for that tool. So having both servers installed costs you little until you use them. If you want Chrome DevTools MCP small anyway, --slim cuts it to three tools (navigate, evaluate, screenshot) in 1.3 KB.
The snapshots are the real cost. A snapshot of my AWS Emulator post, which is long, came to about 50 KB from either server: roughly 12,600 tokens every time the agent looks at the page. Playwright MCP 0.0.86 is clever about this. After a navigation or a click it writes the snapshot to a file and returns a 359-byte reply with a link to it, so the full tree only lands in the conversation when the agent asks for browser_snapshot or opens that file. Chrome DevTools MCP’s click returns one line (“Successfully clicked on the element”) unless you ask for a snapshot with it. On a small page none of this matters. On a long one, an agent that snapshots after every click burns through context fast.
Both projects now say as much themselves. Playwright MCP’s README suggests that coding agents might do better with Playwright CLI and its skills, because CLI calls “avoid loading large tool schemas and verbose accessibility trees”. Chrome DevTools MCP ships a chrome-devtools CLI and skills alongside the server. MCP still makes sense when the agent needs to keep a browser open and work through a page step by step. For a quick look, a CLI call is cheaper.
Where Chrome DevTools MCP earns its place#
Playwright MCP can’t record a performance trace. Chrome DevTools MCP can, and its summary is written for the model to read. Here’s part of what it returned for that same post, from a reload with no throttling, on my Mac in Seoul:
## insight set id: NAVIGATION_0
URL: https://jared.lynskey.co.nz/en/posts/2026/aws-emulator-setup/
Metrics (lab / observed):
- LCP: 498 ms, event: (eventKey: r-4580, ts: 2901865748771), nodeId: 28
- LCP breakdown:
- TTFB: 255 ms
- Load delay: 11 ms
- Load duration: 1 ms
- Render delay: 230 ms
- CLS: 0.00
Metrics (field / real users): n/a – no data for this page in CrUXA follow-up call (performance_analyze_insight with LCPBreakdown) named the LCP element: the cover image, a WebP served from Cloudflare with a one-year immutable cache. Half the 498 ms was waiting for the HTML and the other half was rendering. That fits a site I’d already tuned. A trace isn’t something you’d write a test for every week, but it’s exactly what you want an agent to have to hand when someone says the page feels slow.
The tool I didn’t expect to like was lighthouse_audit. I ran it on the same post, once as desktop and once as mobile, and it found things I hadn’t noticed:

- On desktop, Accessibility scored 96. The table-of-contents links are
#747474on#2a2a2a, a contrast ratio of 3.07:1 against the 4.5:1 that small text needs. - On mobile, Agentic Browsing scored 2 out of 3. This is a new Lighthouse category, which Lighthouse marks as still under development, for how well AI agents can use a site. The failing check was a well-formed accessibility tree: my mobile menu toggle is a
<label>givenrole="button". Thellms.txtcheck passed. - On mobile, it also flagged the post’s two big tables for having data cells without header cells.
Lighthouse’s own report warned that clearing the browser cache timed out on the mobile run, so take its timings with salt. The accessibility findings don’t depend on timing, though, and they’re all fixes I can make. That’s the case for Chrome DevTools MCP in one line: an agent can find the bug and then also tell you what else is wrong with the page.
When you need Claude in Chrome instead#
Both servers start a fresh browser. That’s what you want for testing, and useless for anything behind a login. Claude in Chrome is an extension that lets Claude Code work in your own Chrome or Edge, with your sessions. Start it with claude --chrome, or check and manage it with /chrome. It reads console errors and the DOM, fills forms, uploads files and records GIFs. It needs a direct Anthropic plan rather than an API key, pauses at login pages and CAPTCHAs, and network inspection isn’t on its list of capabilities.
I’ve used it for the kind of job only it can do: work in a dashboard I’m signed in to that has no API. Most recently that was asking a search engine to re-crawl a list of pages, one “request” button at a time. It worked, with quirks. Asking for more than one page per batch timed the extension out, and Escape didn’t close the dialog, though its Dismiss button did. It’s not something to point at a page where a wrong click costs money. If either MCP server could have done it, I’d have used that instead, because a clean, throwaway browser is easier to trust.
Which one I’d install#
For a web project where the agent changes UI, I’d add Playwright MCP at project scope. It’s the one to use for “click through the flow and tell me it works”. Add Chrome DevTools MCP when the question is speed, Lighthouse or network detail. Keep Claude in Chrome for the signed-in jobs nobody can script.
Then, for anything you’ll check more than twice, turn it into a real test. An MCP run costs tokens every time. A Playwright test, once written, runs for free in CI, which is the point the Claude Code team makes too. Plenty of my own browser checks are plain Playwright scripts with no MCP at all. One took the page screenshots for my AWS Emulator post, and another, earlier today, confirmed that some new analytics events fire in the right order. The agent writes the script once, and after that I just run it. When a test fails, the error message is usually the place to start.
Further reading#
On this site:
- Playwright “Test timeout of 30000ms exceeded.”: find the wait that never finished
- MCP vs CLI vs Skills: What Each Costs Your Coding Agent
- How I run Claude Code day to day, on permission modes and tmux
Elsewhere:
- microsoft/playwright-mcp and Playwright CLI
- ChromeDevTools/chrome-devtools-mcp, with its tool reference
- Claude in Chrome and MCP tool search in the Claude Code docs
- How the Claude Code team thinks about verification
