Skip to content

microsoft/Playwright MCP

Playwright MCP server

Playwright MCP is an open-source Model Context Protocol server from Microsoft that lets AI agents drive a real browser via Playwright's accessibility tree, not screenshots. Point an MCP client like Cursor or Claude at it and your agent can navigate, click, and fill forms on live pages.

33,260 stars2,730 forksTypeScript
✅ Reviewed by My AI Guide, vetted for developers

Our Review

Playwright MCP comes from Microsoft, the team behind Playwright itself, and has gathered 33,000 GitHub stars as the standard browser layer for AI coding agents. Its approach: it feeds the agent a structured accessibility snapshot of each page, so actions are deterministic and no vision model is required.

Capabilities exposed:

  • Accessibility-tree navigation the agent reads a structured snapshot of the page and acts on real elements, not screenshots.
  • Core browser actions navigate, click, type, fill forms, select options, and wait for elements through MCP tool calls.
  • Tabs and dialogs open and switch tabs, handle dialogs, and manage multiple pages in one session.
  • Network and console access read network requests and console messages for debugging and verification.
  • Screenshots and PDF capture the page when a visual artifact is needed, even though the default is vision-free.
  • Persistent browser context keep state across calls for long-running, iterative automation loops.

Compatible clients:

  • Cursor, Claude, Windsurf install with the standard npx @playwright/mcp@latest config in any MCP client.
  • VS Code, Goose, and more official one-click installs and config snippets for most major MCP hosts.

Limitations:

Playwright MCP loads a fairly large tool schema into the model context, which costs tokens on every call; Microsoft now points high-throughput coding agents to its CLI plus SKILLS approach instead. It needs Node.js 18 or newer and a working Playwright browser install. As an MCP server it only does what its tool set exposes, so deeply custom automation may still need raw Playwright code.

Our Verdict

Playwright MCP is the most direct way to hand an AI agent a real browser in 2026. If you want your coding assistant to open pages, click through flows, and verify the result without bolting on a vision model, this is the standard choice, backed by Microsoft and the Playwright project.

For developers, the appeal is determinism: actions run against the accessibility tree, so the agent targets real elements instead of guessing pixel coordinates. It drops into Cursor, Claude, Windsurf, and VS Code with one npx config line, and the network and console tools make it useful for debugging and self-healing tests.

Skip Playwright MCP if you are running a high-throughput coding agent where the large tool schema's token cost matters; Microsoft's Playwright CLI with SKILLS is leaner there. If you need bespoke automation logic, raw Playwright code gives more control than the MCP tool set.

Frequently Asked Questions

What is Playwright MCP?

Playwright MCP is an open-source Model Context Protocol server, built by Microsoft, that gives AI agents browser automation through Playwright. It exposes navigation, clicking, form filling, and inspection as MCP tools, and it works off the page's accessibility tree so agents act on structured elements instead of screenshots. Any MCP client can connect to it.

Is Playwright MCP free?

Yes. Playwright MCP is released under the Apache-2.0 license and is free and open source as of 2026. You install it from npm as @playwright/mcp at no cost. Because it runs locally as an MCP server alongside your client, there is no hosted service fee; you only provide the machine it runs on.

Which clients work with Playwright MCP?

Playwright MCP works with any Model Context Protocol client. Microsoft documents one-click or config-based installs for Cursor, Claude Desktop, Windsurf, VS Code, Goose, and Junie, among others. The standard setup adds an entry that runs npx @playwright/mcp@latest, so the same server works across every supported coding agent.

How is Playwright MCP different from screenshot-based browser agents?

Screenshot-based agents send page images to a vision model and infer where to click, which is slower and less reliable. Playwright MCP instead reads the accessibility tree, a structured map of page elements, so actions are deterministic and need no vision model. Choose a screenshot agent when a site is purely visual; choose Playwright MCP when the page has real, accessible structure.

Should I use Playwright MCP or the Playwright CLI?

Choose Playwright MCP for specialized agentic loops that benefit from persistent browser state and iterative reasoning over page structure, such as exploratory automation or self-healing tests. Choose Microsoft's Playwright CLI with SKILLS for high-throughput coding agents, because CLI calls avoid loading a large tool schema into context and are more token-efficient.

How do I install Playwright MCP?

Visit the GitHub repository at https://github.com/microsoft/playwright-mcp for installation instructions.

What license does Playwright MCP use?

Playwright MCP uses the Apache-2.0 license.

What are alternatives to Playwright MCP?

Explore related tools and alternatives on My AI Guide.

🔒

Open source & community-verified

Apache-2.0 licensed: free to use in any project, no strings attached. 33,260 developers have starred this, meaning the community has reviewed and trusted it.

Reviewed by My AI Guide for relevance, quality, and active maintenance before listing.

Topics

mcpplaywright

Related Tools

View all