mcp-playwright
by sandeep-talware
Overview
Automate browser actions programmatically via an MCP protocol server, primarily for LLM interaction.
Installation
node src/server.jsEnvironment Variables
- PORT
- HOST
- CHROME_EXECUTABLE_PATH
- CHROME_START_MAXIMIZED
- RECORDING_ENABLED
- NODE_ENV
- LOG_LEVEL
Security Notes
The server exposes capabilities that allow arbitrary JavaScript execution within the controlled browser context via the `playwright_evaluate` tool, and dynamic network request interception/modification via `playwright_route_request`. If exposed to untrusted clients or integrated with an LLM that might generate malicious code, this poses significant risks, including Cross-Site Scripting (XSS), data exfiltration, or browser exploitation. The included `Validator` primarily checks input structure and types, not the safety of the content. The `README` acknowledges these risks and warns against public exposure without authentication.
Similar Servers
playwright-mcp
Provides a Model Context Protocol (MCP) server for LLMs to automate browser interactions using Playwright's accessibility tree, avoiding pixel-based vision models.
fetcher-mcp
This MCP server is designed for fetching web page content using a Playwright headless browser, enabling intelligent content extraction, JavaScript execution, and flexible output formats.
playwright-mcp-server
Provides a robust, token-aware Playwright browser automation server for Large Language Models (LLMs) and coding agents to interact with web content, supporting advanced features like anti-detection and multi-page management.
mcp-browser-use-server
An MCP server that enables AI agents to control web browsers using the browser-use library, supporting various transports and persistent sessions.