
How to add MCP Server Playwright to Cursor
Browser automation via Playwright — let LLMs navigate, click, fill forms, screenshot, and run JS in a real browser. Paste the config into ~/.cursor/mcp.json and restart Cursor.
Last updated June 14, 2026 · 295★ · stdio · no auth
Cursor config for MCP Server Playwright
npx @automatalabs/mcp-server-playwright install{
"mcpServers": {
"mcp-server-playwright": {
"command": "npx",
"args": [
"-y",
"@automatalabs/mcp-server-playwright"
]
}
}
}Setup steps
- 1Open Cursor → Settings → MCP → Add new MCP server (or edit ~/.cursor/mcp.json directly).
- 2Paste the MCP Server Playwright config below into the "mcpServers" object.
- 3Fill in placeholder secrets, then save.
- 4Cursor reloads MCP servers automatically — check Settings → MCP for a green status dot.
- 5Ask Cursor to use one of MCP Server Playwright's tools to confirm it's connected.
Before you start
- Node.js with npx available in PATH
- Playwright browsers installed (npx playwright install)
- Windows or macOS (the automated installer checks OS compatibility)
What MCP Server Playwright can do in Cursor
browser_navigateNavigate to any URL in the browser.
browser_screenshotCapture a screenshot of the entire page or a specific element. Accepts name (required), optional selector, and optional fullPage flag.
browser_clickClick an element on the page using a CSS selector.
browser_click_textClick an element on the page by its text content.
browser_hoverHover over an element on the page using a CSS selector.
browser_hover_textHover over an element on the page by its text content.
browser_fillFill out an input field given a selector and value.
browser_selectSelect an option in a SELECT element using a CSS selector.
Security
Runs a real browser locally and executes arbitrary JavaScript supplied by the model via browser_evaluate, and navigates to any URL. Treat model-driven navigation and script execution as untrusted; avoid using on machines with sensitive logged-in browser sessions.
MCP Server Playwright + Cursor FAQ
Where is the Cursor config file?
Cursor reads MCP servers from ~/.cursor/mcp.json. Paste the MCP Server Playwright config there under the "mcpServers" key and restart the client.
Is MCP Server Playwright safe to use with Cursor?
Runs a real browser locally and executes arbitrary JavaScript supplied by the model via browser_evaluate, and navigates to any URL. Treat model-driven navigation and script execution as untrusted; avoid using on machines with sensitive logged-in browser sessions.
How do I install it?
Run `npx @automatalabs/mcp-server-playwright install`, which checks OS compatibility and creates/updates your Claude Desktop config. Alternatively install via Smithery: `npx -y @smithery/cli install @automatalabs/mcp-server-playwright --client claude` (or `--client cursor`).
Can I use it with Cursor?
Yes. Install Playwright browsers with `npx playwright install`, then run the Smithery installer with `--client cursor`. If you do not use Claude, you may need to manually create claude_desktop_config.json as described in the README.
What resources does it expose?
Browser console logs at `console://logs` (text) and captured screenshots at `screenshot://<name>` (PNG, referenced by the name given during capture).