playwright-mcp icon

playwright-mcp

Inspect and control a browser through structured page snapshots.
playwright-mcp icon

About playwright-mcpv0.0.83

Last updated on

Playwright MCP connects an AI assistant to a browser through the Model Context Protocol. It shows the assistant a structured snapshot of a page’s elements, roles, and text. The assistant can then navigate, click, fill forms, and inspect what changed. For developers on Linux, this offers a way to investigate a live interface while working on the code behind it.

What can Playwright MCP do?

Its core browser tools cover navigation, form entry, tabs, screenshots, console messages, and network requests. An assistant could follow a checkout flow, check whether a settings form saved correctly, or inspect a page after an error. Accessibility snapshots make controls available as text references; screenshots help when layout or visual state matters.

Playwright MCP is most useful for tasks that develop as the assistant explores. It can inspect the current page, take an action, and use the next result to decide where to go. That flexibility comes with a cost: large page snapshots can take up considerable room in an agent’s context.

Using Playwright MCP on Linux

Add @playwright/mcp to an MCP-capable client such as Codex, Claude Code, or VS Code. In the standard setup, your MCP client starts Playwright MCP with npx and opens a visible browser. Add --headless to run it without a window.

When should I use Playwright MCP rather than Playwright CLI and skills?

Choose MCP when the assistant benefits from inspecting page structure and working through an open-ended browser session. Microsoft’s separate Playwright CLI and skills give coding agents concise browser commands and keep page data out of the model context unless needed. The CLI can also retain browser state during a session; the distinction is its command-based workflow, not an inability to maintain one.

For a different task, Chrome DevTools MCP focuses on Chrome debugging and performance traces. If you need an authored test suite with assertions that runs in CI, Playwright Test is the dedicated framework.

How do browser-session settings affect repeatable automation?

Playwright MCP saves cookies and login state in a persistent profile by default. That helps with continued work, but an earlier login can change how a later run behaves. Use --isolated for a fresh session, or load a known storage-state file when a task needs a specific authenticated starting point. Keep the browser, viewport, and starting state consistent when comparing runs.

Supported platforms

Latest version

v0.0.83

Requirements

  • - Node.js 18 or newer
  • - VS Code
  • Cursor
  • Windsurf
  • Claude Desktop
  • Goose
  • Grok
  • Junie or any other MCP client

Rate this app

No ratings yet

No comment yet

Be the first to share your thoughts.

License

Apache-2.0

Latest version

v0.0.83
Report incorrect information

Recently updated software