
A Model Context Protocol server that provides browser automation capabilities using Playwright. This server enables LLMs to interact with web pages, take screenshots, and execute JavaScript in a real browser environment.

Screenshot

Installation
You can install the package using either npm, mcp-get, or Smithery:
Using npm:
npm install -g @executeautomation/playwright-mcp-server
Using mcp-get:
npx @michaellatman/mcp-get@latest install @executeautomation/playwright-mcp-server
Using Smithery
To install Playwright MCP for Claude Desktop automatically via Smithery:
npx @smithery/cli install @executeautomation/playwright-mcp-server --client claude
Configuration to use Playwright Server
Here's the Claude Desktop configuration to use the Playwright server:
{
"mcpServers": {
"playwright": {
"command": "npx",
"args": ["-y", "@executeautomation/playwright-mcp-server"]
}
}
}
[
{
"description": "Navigate to a URL",
"inputSchema": {
"properties": {
"url": {
"type": "string"
}
},
"required": [
"url"
],
"type": "object"
},
"name": "playwright_navigate"
},
{
"description": "Take a screenshot of the current page or a specific element",
"inputSchema": {
"properties": {
"downloadsDir": {
"description": "Custom downloads directory path (default: user's Downloads folder)",
"type": "string"
},
"height": {
"description": "Height in pixels (default: 600)",
"type": "number"
},
"name": {
"description": "Name for the screenshot",
"type": "string"
},
"savePng": {
"description": "Save screenshot as PNG file (default: false)",
"type": "boolean"
},
"selector": {
"description": "CSS selector for element to screenshot",
"type": "string"
},
"storeBase64": {
"description": "Store screenshot in base64 format (default: true)",
"type": "boolean"
},
"width": {
"description": "Width in pixels (default: 800)",
"type": "number"
}
},
"required": [
"name"
],
"type": "object"
},
"name": "playwright_screenshot"
},
{
"description": "Click an element on the page",
"inputSchema": {
"properties": {
"selector": {
"description": "CSS selector for element to click",
"type": "string"
}
},
"required": [
"selector"
],
"type": "object"
},
"name": "playwright_click"
},
{
"description": "fill out an input field",
"inputSchema": {
"properties": {
"selector": {
"description": "CSS selector for input field",
"type": "string"
},
"value": {
"description": "Value to fill",
"type": "string"
}
},
"required": [
"selector",
"value"
],
"type": "object"
},
"name": "playwright_fill"
},
{
"description": "Select an element on the page with Select tag",
"inputSchema": {
"properties": {
"selector": {
"description": "CSS selector for element to select",
"type": "string"
},
"value": {
"description": "Value to select",
"type": "string"
}
},
"required": [
"selector",
"value"
],
"type": "object"
},
"name": "playwright_select"
},
{
"description": "Hover an element on the page",
"inputSchema": {
"properties": {
"selector": {
"description": "CSS selector for element to hover",
"type": "string"
}
},
"required": [
"selector"
],
"type": "object"
},
"name": "playwright_hover"
},
{
"description": "Execute JavaScript in the browser console",
"inputSchema": {
"properties": {
"script": {
"description": "JavaScript code to execute",
"type": "string"
}
},
"required": [
"script"
],
"type": "object"
},
"name": "playwright_evaluate"
},
{
"description": "Perform an HTTP GET request",
"inputSchema": {
"properties": {
"url": {
"description": "URL to perform GET operation",
"type": "string"
}
},
"required": [
"url"
],
"type": "object"
},
"name": "playwright_get"
},
{
"description": "Perform an HTTP POST request",
"inputSchema": {
"properties": {
"url": {
"description": "URL to perform POST operation",
"type": "string"
},
"value": {
"description": "Data to post in the body",
"type": "string"
}
},
"required": [
"url",
"value"
],
"type": "object"
},
"name": "playwright_post"
},
{
"description": "Perform an HTTP PUT request",
"inputSchema": {
"properties": {
"url": {
"description": "URL to perform PUT operation",
"type": "string"
},
"value": {
"description": "Data to PUT in the body",
"type": "string"
}
},
"required": [
"url",
"value"
],
"type": "object"
},
"name": "playwright_put"
},
{
"description": "Perform an HTTP PATCH request",
"inputSchema": {
"properties": {
"url": {
"description": "URL to perform PUT operation",
"type": "string"
},
"value": {
"description": "Data to PATCH in the body",
"type": "string"
}
},
"required": [
"url",
"value"
],
"type": "object"
},
"name": "playwright_patch"
},
{
"description": "Perform an HTTP DELETE request",
"inputSchema": {
"properties": {
"url": {
"description": "URL to perform DELETE operation",
"type": "string"
}
},
"required": [
"url"
],
"type": "object"
},
"name": "playwright_delete"
}
]