MCP Server Playwright

Provides browser automation through Playwright for an MCP server, enabling pages interaction, screenshots, and JS execution.
  • javascript

1

GitHub Stars

javascript

Language

6 months ago

First Indexed

2 months ago

Catalog Refreshed

Documentation & install

Readme and setup notes from the catalogue, plus a client-ready config you can copy for your MCP host.

Installation

Add the following to your MCP client configuration file.

Configuration

View docs
{
  "mcpServers": {
    "mcp-mirror-automata-labs-team_mcp-server-playwright": {
      "command": "npx",
      "args": [
        "-y",
        "@automatalabs/mcp-server-playwright"
      ]
    }
  }
}

You can run an MCP server that automates a real browser using Playwright. This enables you to navigate web pages, take screenshots, fill forms, and run JavaScript in a live browser context as part of your MCP workflow.

How to use

You use this server by connecting an MCP client that supports the MCP protocol. Once connected, you can issue high-level browser automation actions to control a Playwright-driven browser embedded in the MCP server. Practical use cases include navigating to web pages, taking full-page or element-specific screenshots, clicking or hovering elements, filling forms, selecting options, and evaluating JavaScript in the browser context. The server streams browser console output and can return captured screenshots or other results to your client for further processing.

How to install

Prerequisites: ensure you have Node.js and npm installed on your machine. You may also use npx or a dedicated MCP installer as described below.

Install via Smithery for Claude Desktop automation integration:

npx @smithery/cli install @automatalabs/mcp-server-playwright --client claude

Install the MCP server package directly with npx if you are not using Smithery, which will also create or update the integration config for you:

npx @automatalabs/mcp-server-playwright install

Alternatively, you can use the MCP installer helper to add the server using a dedicated installer tool:

npx @michaellatman/mcp-get@latest install @automatalabs/mcp-server-playwright

After installation, the configuration will include an MCP server entry that runs the Playwright server via npx.

Configuration

The installation automatically adds a server entry that uses a local stdio-based MCP command. The default configuration looks like this in your MCP settings:

{
  "mcpServers": {
    "playwright": {
      "command": "npx",
      "args": ["-y", "@automatalabs/mcp-server-playwright"]
    }
  }
}

Resources and capabilities

The Playwright MCP server provides tools to interact with the browser and retrieve results such as console logs and screenshots.

Available actions include navigating to URLs, taking full-page or element-specific screenshots, clicking or hovering elements by CSS selector or by visible text, filling inputs, selecting options, and evaluating JavaScript in the browser context.

Tools

The server exposes a set of tool endpoints you can invoke from your MCP client. These include actions for navigation, interaction, and data capture in the browser.

Troubleshooting

If you encounter connection or automation issues, verify that the MCP server process is running, your client is configured to connect to the correct stdio channel, and the Playwright dependencies are installed in your environment. Check for any permission errors when launching browsers in constrained environments and ensure network access is available for any remote resources the browser may load.

Notes

This server integrates browser automation into your MCP workflow, enabling automated web interactions, screenshot capture, and in-browser JavaScript execution in a controlled, programmatic way.

Available tools

playwright_navigate

Navigate to a URL within the browser context, changing the current page to the provided address.

playwright_screenshot

Capture a screenshot of the entire page or a specific element. You can name the screenshot, choose a selector, and opt for full-page captures.

playwright_click

Click elements on the page using a CSS selector to trigger actions and events.

playwright_click_text

Click elements by matching their visible text content.

playwright_hover

Hover the mouse over elements identified by a CSS selector to reveal hidden menus or tooltips.

playwright_hover_text

Hover over elements by their visible text content.

playwright_fill

Fill input fields with specified values to simulate user input.

playwright_select

Select an option in a SELECT element using a CSS selector and a value.

playwright_select_text

Select an option in a SELECT element by its visible text content.

playwright_evaluate

Execute JavaScript in the browser context and return the result.

Built by
VeilStrat
AI signals for GTM teams
© 2026 VeilStrat. All rights reserved.All systems operational