Playwright MCP

by Playwright-os

50 downloads Not rated yet
GitHub

About

A Model Context Protocol (MCP) server that provides browser automation capabilities using Playwright. Enables LLMs to interact with web pages through structured accessibility snapshots, bypassing the need for screenshots or visually-tuned models.

Explore

- Provides browser automation via Playwright
- Uses structured accessibility snapshots for LLM interaction
- Bypasses need for screenshots or visually-tuned models

Setting up with Highlight

This MCP is not yet compatible with Highlight’s one-click setup. However, you can still use it with Highlight by following these steps:

  1. Download and install Highlight from highlightai.com/download
  2. Navigate to the plugins tab and select "Add Custom Plugin"
  3. Configure the plugin with the settings below
    Plugin Name Playwright MCP
    Command (node, npx, python, etc.)

    Please refer to the README for specific instructions on how to obtain API keys or other required environment variables.

  4. Enable "Start Automatically" if you want the plugin to start when Highlight launches

From the repository

—

browser_close

Close the page

browser_resize

Resize the browser window

browser_console_messages

Returns all console messages

browser_handle_dialog

Handle a dialog

browser_evaluate

Evaluate JavaScript expression on page or element

browser_file_upload

Upload one or multiple files

browser_drop

Drop files or MIME-typed data onto an element, as if dragged from outside the page. At least one of "paths" or "data" must be provided.

browser_find

Search the accessibility snapshot of the current page for text or a regular expression. Returns matching snapshot nodes with a few lines of surrounding context (like search snippets), each shown under its path from the root of the tree, which is cheaper than capturing the whole snapshot when you only need to locate an element and its ref.

browser_fill_form

Fill multiple form fields

browser_press_key

Press a key on the keyboard

browser_type

Type text into editable element

browser_navigate

Navigate to a URL

browser_navigate_back

Go back to the previous page in the history

browser_network_requests

Returns a numbered list of network requests since loading the page. Use browser_network_request with the number to get full details.

browser_network_request

Returns full details (headers and body) of a single network request, or a single part if `part` is set. Use the number from browser_network_requests.

browser_run_code_unsafe

Run a Playwright code snippet. Unsafe: executes arbitrary JavaScript in the Playwright server process and is RCE-equivalent.

browser_take_screenshot

Take a screenshot of the current page. You can't perform actions based on the screenshot, use browser_snapshot for actions.

browser_snapshot

Capture accessibility snapshot of the current page, this is better than screenshot

browser_click

Perform click on a web page

browser_drag

Perform drag and drop between two elements

browser_hover

Hover over element on page

browser_select_option

Select an option in a dropdown

browser_tabs

List, create, close, or select a browser tab.

browser_wait_for

Wait for text to appear or disappear or a specified time to pass

- browser_close: Close the page
- browser_resize: Resize the browser window
- browser_console_messages: Returns all console messages
- browser_handle_dialog: Handle a dialog
- browser_evaluate: Evaluate JavaScript expression on page or element
- browser_file_upload: Upload one or multiple files
- browser_drop: Drop files or MIME-typed data onto an element, as if dragged from outside the page. At least one of "paths" or "data" must be provided.
- browser_find: Search the accessibility snapshot of the current page for text or a regular expression. Returns matching snapshot nodes with a few lines of surrounding context (like search snippets), each shown under its path from the root of the tree, which is cheaper than capturing the whole snapshot when you only need to locate an element and its ref.
- browser_fill_form: Fill multiple form fields
- browser_press_key: Press a key on the keyboard
- browser_type: Type text into editable element
- browser_navigate: Navigate to a URL
- browser_navigate_back: Go back to the previous page in the history
- browser_network_requests: Returns a numbered list of network requests since loading the page. Use browser_network_request with the number to get full details.
- browser_network_request: Returns full details (headers and body) of a single network request, or a single part if part is set. Use the number from browser_network_requests.
- browser_run_code_unsafe: Run a Playwright code snippet. Unsafe: executes arbitrary JavaScript in the Playwright server process and is RCE-equivalent.
- browser_take_screenshot: Take a screenshot of the current page. You can't perform actions based on the screenshot, use browser_snapshot for actions.
- browser_snapshot: Capture accessibility snapshot of the current page, this is better than screenshot
- browser_click: Perform click on a web page
- browser_drag: Perform drag and drop between two elements
- browser_hover: Hover over element on page
- browser_select_option: Select an option in a dropdown
- browser_tabs: List, create, close, or select a browser tab.
- browser_wait_for: Wait for text to appear or disappear or a specified time to pass

Claude Desktop / Cursor

Paste into your MCP client config file to install this server.

{
    "mcpServers": {
        "playwright mcp": {
            "playwright": {
                "command": "npx",
                "args": [
                    "playright-mcp@latest"
                ]
            }
        }
    }
}

McpServers

{
    "playwright": {
        "command": "npx",
        "args": [
            "playright-mcp@latest"
        ]
    }
}

A Model Context Protocol (MCP) server that provides browser automation capabilities using Playwright. Enables LLMs to interact with web pages through structured accessibility snapshots, bypassing the need for screenshots or visually-tuned models.

No reviews yet — be the first

Sign in to leave a review

Use Google, GitHub, or an email account so ratings stay tied to real people.

Email sign in

No reviews posted yet.