---
title: "Playwright: setup for Claude, Cursor, Codex · DotsAgent"
description: "Controls a real browser through accessibility snapshots, so an agent can navigate, click and fill in forms. Set up Playwright in 13 MCP clients."
url: https://dotsagent.io/mcp/servers/playwright
---

Browser automation · Microsoft

# Set up Playwright

Controls a real browser through accessibility snapshots, so an agent can navigate, click and fill in forms.

- **Publisher**: Microsoft Official
- **Run locally**: `npx @playwright/mcp@latest`
- **Transports**: stdio, streamable-http
- **Authentication**: None.
- **What it can touch**: Acts in a browser session: clicks, types and submits.
- **Licence**: Apache-2.0
- **Source**: [github.com/microsoft/playwright-mcp](https://github.com/microsoft/playwright-mcp)
- **Status**: Active

## Install

This server runs on your machine as a child process of the client. You need the runtime its command uses, such as Node.js for npx, uv for uvx or Docker, plus any variables listed under Environment.

### Claude Code

`shell`

```
claude mcp add --scope project playwright -- npx @playwright/mcp@latest
```

### Cursor

`.cursor/mcp.json`

```
{
  "mcpServers": {
    "playwright": {
      "command": "npx",
      "args": [
        "@playwright/mcp@latest"
      ]
    }
  }
}
```

### Codex

`~/.codex/config.toml`

```
[mcp_servers.playwright]
command = "npx"
args = ["@playwright/mcp@latest"]
```

[Config for other clients →](https://dotsagent.io/mcp/config#add=playwright)

## Other servers in browser automation

- [Chrome DevTools](https://dotsagent.io/mcp/servers/chrome-devtools): Drives Chrome and exposes DevTools data such as network requests, console output and performance traces.

## Sources

1. [github.com](https://github.com/microsoft/playwright-mcp)/microsoft/playwright-mcp

Independent reference for people who build AI agents. Not affiliated with any vendor named here.

© 2026 DotsAgent · Facts checked October 1, 2026
