Playwright MCP
Click on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@Playwright MCPNavigate to google.com and search for 'MCP servers'"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
Playwright MCP
An MCP server that gives compatible clients structured control of a real Playwright browser for QA, scraping diagnostics, accessibility-minded inspection, and reproducible browser workflows.
Architecture
Transport entrypoints are thin:
src/index.tsstarts MCP over stdio.src/http.tsstarts MCP over Streamable HTTP.src/server.tsbuilds oneMcpServerand registers all tools.
Core services own browser state:
BrowserManagerserializes tool execution, launches browsers lazily, and manages contexts/pages.TelemetryStorecaptures console messages, page errors, failed requests, and recent network events.Tool modules register focused actions and depend only on the public browser/session APIs.
Tool groups:
Browser/context/page lifecycle
Navigation and waiting
Interaction
Inspection and screenshots
Assertions
Diagnostics, tracing, and storage
Related MCP server: Playwright Server MCP
Install
npm install
npm run install-browsers
npm run buildRun
npm startHTTP transport:
npm run start:httpDefault HTTP endpoint: http://127.0.0.1:8931/mcp.
Production Controls
Configuration is environment-driven:
PLAYWRIGHT_MCP_HTTP_TOKEN: requireAuthorization: Bearer <token>for HTTP mode.PLAYWRIGHT_MCP_HTTP_ALLOWED_ORIGINS: comma-separated CORS allowlist.PLAYWRIGHT_MCP_ALLOWED_ORIGINS: comma-separated browser navigation allowlist.PLAYWRIGHT_MCP_BLOCKED_ORIGINS: comma-separated browser navigation blocklist.PLAYWRIGHT_MCP_ALLOW_EVALUATE: enable the dangerousevaluatetool. Default:false.PLAYWRIGHT_MCP_ALLOW_DOWNLOADS: enable download tools and accepting downloads. Default:false.PLAYWRIGHT_MCP_ALLOW_UPLOADS: enable upload tools. Default:false.PLAYWRIGHT_MCP_ARTIFACT_DIR: screenshots, traces, PDFs, downloads, and storage state directory. Default:./artifacts.PLAYWRIGHT_MCP_MAX_CONTEXTS: browser context cap. Default:8.PLAYWRIGHT_MCP_MAX_PAGES: page cap. Default:32.PLAYWRIGHT_MCP_DEFAULT_TIMEOUT_MS: default Playwright timeout. Default:30000.PLAYWRIGHT_MCP_LOG_LEVEL:debug,info,warn, orerror.
HTTP mode should use PLAYWRIGHT_MCP_HTTP_TOKEN before binding to anything other than localhost.
MCP client config
Examples are available in examples/:
claude_config.jsoncursor_mcp.jsoncodex_config.tomlcline_mcp_settings.jsonopencode_config.json
Development
npm run checkThis server cannot be deployed
Maintenance
Related MCP Connectors
MCP server for Mint — AI-powered QA that runs your app in a real browser on every PR.
Browserless MCP — wraps the Browserless headless-Chromium REST API (browserless.io)
MCP server for visual regression testing: triage a PR's UI diffs from your coding agent.
MCP server to assist with JxBrowser development.
Related MCP Servers
- AlicenseBqualityNot gradedmaintenanceA MCP server that provides browser automation tools, allowing users to navigate websites, take screenshots, click elements, fill forms, and execute JavaScript through Playwright.82Apache 2.0
- AlicenseBqualityDmaintenanceA browser automation server providing Playwright capabilities for controlling web browsers, capturing screenshots, extracting content, and performing complex interactions through an MCP interface.6Apache 2.0
- AlicenseNot gradedqualityNot gradedmaintenanceA Playwright-based MCP server that exposes a live browser as a traceable, inspectable, debuggable and controllable execution environment for AI agents.5,153 npm57-
- AlicenseBqualityDmaintenanceA universal browser automation MCP server using Playwright, enabling programmatic control of Chrome with 63 tools for navigation, interaction, media control, and CDP-based diagnostics.639 npm3MIT