# Playwright MCP

Open-source MCP server that lets an agent drive a local browser through page accessibility snapshots, returning page state as text.

- Provider: Microsoft (https://github.com/microsoft/playwright-mcp)
- Category: Drive a browser
- Type: Runs on your machine
- Pricing model: Free, open source [2]
- Free tier: Not applicable; the software is free to run [2]
- Authentication: None; runs locally over stdio [5]
- Connect via: Local MCP server over stdio or HTTP, run with `npx @playwright/mcp@latest` [1]
- Read from the provider's pages on 2026-11-04
- Page: https://supermarket.dev/tools/drive-a-browser/playwright-mcp

## Pricing

### Billing
- Pricing model: Free, open source [2]
- Free tier: Whole package is free; no paid tier [2]
- Card required for free tier: No [2]
- Minimum spend: Not published
- Billing period: Not published

### Prices
The browser runs on your own machine, so there is no per-browser-hour price.
- Price: Free [3]

## Tools

### MCP server
- Official MCP server: Yes, local [5]
- Address or package: npm package `@playwright/mcp`; run with `npx @playwright/mcp@latest` [5]

### MCP tools
25 tools are on by default; 47 more load with `--caps` groups. The Read-only column is the README's own label for each tool. Pages can also register tools that appear as `webmcp_<tool>`.
| Tool | What it does | Read-only |
|---|---|---|
| `browser_click` | Perform click on a web page | No |
| `browser_close` | Close the page | No |
| `browser_console_messages` | Returns all console messages | Yes |
| `browser_drag` | Perform drag and drop between two elements | No |
| `browser_drop` | Drop files or MIME-typed data onto an element | No |
| `browser_emulate_media` | Emulate CSS media features, such as light or dark color scheme | No |
| `browser_evaluate` | Evaluate JavaScript expression on page or element | No |
| `browser_file_upload` | Upload one or multiple files | No |
| `browser_fill_form` | Fill multiple form fields | No |
| `browser_find` | Search the accessibility snapshot for text or a regular expression and return matching nodes | Yes |
| `browser_handle_dialog` | Handle a dialog | No |
| `browser_hover` | Hover over element on page | No |
| `browser_navigate` | Navigate to a URL | No |
| `browser_navigate_back` | Go back to the previous page in the history | No |
| `browser_network_request` | Returns full details (headers and body) of a single network request | Yes |
| `browser_network_requests` | Returns a numbered list of network requests since loading the page | Yes |
| `browser_press_key` | Press a key on the keyboard | No |
| `browser_resize` | Resize the browser window | No |
| `browser_run_code_unsafe` | Run a Playwright code snippet; executes arbitrary JavaScript in the server process and is RCE-equivalent | No |
| `browser_select_option` | Select an option in a dropdown | No |
| `browser_snapshot` | Capture accessibility snapshot of the current page | Yes |
| `browser_take_screenshot` | Take a screenshot of the current page; actions cannot be based on it | Yes |
| `browser_type` | Type text into editable element | No |
| `browser_wait_for` | Wait for text to appear or disappear or a specified time to pass | No |
| `browser_tabs` | List, create, close, or select a browser tab | No |
| `--caps=storage` (17 tools) | Get, set, list, delete and clear cookies, localStorage and sessionStorage; save and restore storage state from a file | Mixed: reads Yes, writes No |
| `--caps=devtools` (13 tools) | Tracing, video recording and chapters, action recording, element highlight, annotation, resume | Mostly Yes; `browser_resume` No |
| `--caps=vision` (6 tools) | Coordinate-based mouse tools: click, move, drag, down, up, wheel | No |
| `--caps=testing` (5 tools) | Test assertions: generate locator, verify element, list, text and value | `browser_generate_locator` Yes; verify tools No |
| `--caps=network` (4 tools) | Mock network requests with routes, list and remove routes, set online or offline | `browser_route_list` Yes; others No |
| `--caps=pdf` (1 tool) | `browser_pdf_save` saves the page as PDF | Yes |
| `--caps=config` (1 tool) | `browser_get_config` returns the resolved config | Yes |
Source [1]

### API
No hosted API. The server is reached over MCP only.
| Endpoint | What it does |
|---|---|
| `http://localhost:8931/mcp` | HTTP endpoint for MCP clients, when started with `--port 8931` |
Source [1]

### Features
- Where the browser runs: Your own machine; Docker image runs headless Chromium [1]
- Browsers: chrome, firefox, webkit, msedge [1]
- Max session length: Not published
- Concurrent sessions: One browser instance per persistent profile; extra clients need `--isolated` or their own `--user-data-dir` [1]
- Proxies: Supported with `--proxy-server` (HTTP or SOCKS5) and `--proxy-bypass` [1]
- CAPTCHA solving: Not published
- Session recording: Video and trace recording tools in the opt-in `devtools` group; `--save-session` saves the session [1]
- Persistent logins: Yes, by default; `--isolated` keeps the profile in memory instead [1]

## Authentication

### Methods
| Method | Used for | How |
|---|---|---|
| None | Local stdio server | Client launches `npx @playwright/mcp@latest`; no key or account |
Source [5]

### Getting access
- Who creates the account: No account needed [2]
- Where to get a key: No key [5]
- Other requirements: Node.js 18 or newer, per the README; a browser such as Chrome [1]

## Setup

### Addresses
- REST API: Not published
- MCP server: `http://localhost:8931/mcp` when started with `--port 8931`; stdio by default [1]
- OpenAPI spec: Not published
- Docs for agents: Not published
- Status page: Not published

### Install
| What | Command |
|---|---|
| Claude Code | `claude mcp add playwright npx @playwright/mcp@latest` |
| Codex | `codex mcp add playwright npx "@playwright/mcp@latest"` |
| VS Code | `code --add-mcp '{"name":"playwright","command":"npx","args":["@playwright/mcp@latest"]}'` |
| Amp | `amp mcp add playwright -- npx @playwright/mcp@latest` |
| Factory | `droid mcp add playwright "npx @playwright/mcp@latest"` |
| Grok | `grok mcp add playwright -- npx @playwright/mcp@latest` |
| Other MCP clients | Standard config: `{"mcpServers":{"playwright":{"command":"npx","args":["@playwright/mcp@latest"]}}}` |
| HTTP mode | `npx @playwright/mcp@latest --port 8931` |
Source [1]

## Limits

### Rate limits
- Rate limit: Not published

### Other limits
- Action timeout: 5000 ms by default [1]
- Navigation timeout: 60000 ms by default [1]
- Idle timeout: Headless browsers close after one hour idle; headed browsers never [1]

## Privacy

### Your data
- Data location: On your machine; the profile is stored in a local cache folder [1]
- Retention: Profile persists until you delete it [1]
- Used for training: Not published
- Zero data retention: Not published

### Compliance
- Certifications: Not published
- HIPAA: Not published
- Security boundary: Not a security boundary [1]

## Sources

1. README: https://raw.githubusercontent.com/microsoft/playwright-mcp/main/README.md
2. package.json: https://raw.githubusercontent.com/microsoft/playwright-mcp/main/package.json
3. LICENSE: https://raw.githubusercontent.com/microsoft/playwright-mcp/main/LICENSE
4. SECURITY.md: https://raw.githubusercontent.com/microsoft/playwright-mcp/main/SECURITY.md
5. server.json: https://raw.githubusercontent.com/microsoft/playwright-mcp/main/server.json
6. Checked by supermarket.dev
