- Home
- MCP servers
- Playwright
Playwright
- typescript
0
GitHub Stars
typescript
Language
6 months ago
First Indexed
3 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.
This Playwright MCP Server enables you to automate and control RoxyBrowser’s RoxyChrome-based browsers through AI using structured accessibility data. It offers fast, deterministic browser interactions without relying on pixel-based vision models, making it ideal for AI-driven workflows that need reliable page access and manipulation.
How to use
You can connect your MCP client to the Playwright MCP server to automate web pages using structured accessibility snapshots. Choose between a local STDIO server (running in your environment) or a remote HTTP endpoint, then issue high-level automation commands through the MCP client.
How to install
Prerequisites you need before installing:
-
Node.js 18 or newer
-
An MCP client such as VS Code, Cursor, Windsurf, Claude Desktop, Goose, or another MCP client
Install the Playwright MCP server using the standard configuration and then start it.
Configuration and usage notes
{
"mcpServers": {
"playwright": {
"command": "npx",
"args": ["@playwright/mcp@latest"]
}
}
}
Standalone and HTTP connectivity
If you run the MCP server in a headed environment and want HTTP transport, you can start it with a port and connect clients via an HTTP URL.
Example HTTP client configuration to connect to a locally hosted HTTP endpoint:
{
"mcpServers": {
"playwright": {
"url": "http://localhost:8931/mcp"
}
}
}
Alternative STDIO configuration
To run the server locally as an STDIO process, you start the MCP server with the standard command and arguments.
{
"mcpServers": {
"playwright": {
"command": "npx",
"args": ["@playwright/mcp@latest"]
}
}
}
Available tools
browser_click
Perform click on a web page. Requires an element description and a page reference.
browser_close
Close the current browser page or tab.
browser_connect_roxy
Connect to a RoxyBrowser instance using a CDP WebSocket endpoint.
browser_console_messages
Retrieve all console messages from the current page.
browser_drag
Drag between two elements using their references.
browser_evaluate
Evaluate a JavaScript expression on the page or a specific element.
browser_file_upload
Upload one or multiple files to an input element.
browser_handle_dialog
Handle a dialog by choosing to accept or dismiss, with optional prompt text.
browser_hover
Hover the mouse over a target element.
browser_navigate
Navigate the browser to a specified URL.
browser_navigate_back
Go back to the previous page.
browser_navigate_forward
Go forward to the next page.
browser_network_requests
List network requests captured since the page load.
browser_press_key
Press a keyboard key or input a character.
browser_resize
Resize the browser window to specified dimensions.
browser_select_option
Select one or more options in a dropdown element.
browser_snapshot
Capture an accessibility snapshot of the current page.
browser_take_screenshot
Take a screenshot of the current viewport or element.
browser_type
Type text into an editable element.
browser_wait_for
Wait for text to appear or disappear or for a time duration to pass.
browser_tab_close
Close a specific tab by index or the current tab.
browser_tab_list
List all open tabs.
browser_tab_new
Open a new tab to a specified URL or a blank page.
browser_tab_select
Select a tab by index.
browser_install
Install the browser specified in the config.
browser_mouse_click_xy
Click at a given screen position.
browser_mouse_drag_xy
Drag the mouse from a start position to an end position.
browser_mouse_move_xy
Move the mouse to a given position.
browser_pdf_save
Save the current page as a PDF.