@spiceman161

Playwright MCP

Browser automation via Playwright MCP server. Navigate websites, click elements, fill forms, extract data, take screenshots, and perform full browser automation workflows.

当前版本
v1.0.0
116 3.4万总安装 494

name: playwright-mcp description: Browser automation via Playwright MCP server. Navigate websites, click elements, fill forms, extract data, take screenshots, and perform full browser automation workflows. metadata: {"openclaw":{"emoji":"🎭","os":["linux","darwin","win32"],"requires":{"bins":["playwright-mcp","npx"]},"install":[{"id":"npm-playwright-mcp","kind":"npm","package":"@playwright/mcp","bins":["playwright-mcp"],"label":"Install Playwright MCP"}]}}

Playwright MCP Skill

Browser automation powered by Playwright MCP server. Control Chrome, Firefox, or WebKit programmatically.

Installation

npm install -g @playwright/mcp
# Or
npx @playwright/mcp

Install browsers (first time):

npx playwright install chromium

Quick Start

Start MCP Server (STDIO mode)

npx @playwright/mcp

Start with Options

# Headless mode
npx @playwright/mcp --headless

# Specific browser
npx @playwright/mcp --browser firefox

# With viewport
npx @playwright/mcp --viewport-size 1280x720

# Ignore HTTPS errors
npx @playwright/mcp --ignore-https-errors

Common Use Cases

1. Navigate and Extract Data

# MCP tools available:
# - browser_navigate: Open URL
# - browser_click: Click element
# - browser_type: Type text
# - browser_select_option: Select dropdown
# - browser_get_text: Extract text content
# - browser_evaluate: Run JavaScript
# - browser_snapshot: Get page structure
# - browser_close: Close browser

2. Form Interaction

1. browser_navigate to form URL
2. browser_type into input fields
3. browser_click to submit
4. browser_get_text to verify result

3. Data Extraction

1. browser_navigate to page
2. browser_evaluate to run extraction script
3. Parse returned JSON data

MCP Tools Reference

ToolDescription
browser_navigateNavigate to URL
browser_clickClick element by selector
browser_typeType text into input
browser_select_optionSelect dropdown option
browser_get_textGet text content
browser_evaluateExecute JavaScript
browser_snapshotGet accessible page snapshot
browser_closeClose browser context
browser_choose_fileUpload file
browser_pressPress keyboard key

Configuration Options

# Security
--allowed-hosts example.com,api.example.com
--blocked-origins malicious.com
--ignore-https-errors

# Browser settings
--browser chromium|firefox|webkit
--headless
--viewport-size 1920x1080
--user-agent "Custom Agent"

# Timeouts
--timeout-action 10000      # Action timeout (ms)
--timeout-navigation 30000  # Navigation timeout (ms)

# Output
--output-dir ./playwright-output
--save-trace
--save-video 1280x720

Examples

Login to Website

browser_navigate: { url: "https://example.com/login" }
browser_type: { selector: "#username", text: "user" }
browser_type: { selector: "#password", text: "pass" }
browser_click: { selector: "#submit" }
browser_get_text: { selector: ".welcome-message" }

Extract Table Data

browser_navigate: { url: "https://example.com/data" }
browser_evaluate: { 
  script: "() => { return Array.from(document.querySelectorAll('table tr')).map(r => r.textContent); }" 
}

Screenshot

browser_navigate: { url: "https://example.com" }
browser_evaluate: { script: "() => { document.body.style.zoom = 1; return true; }" }
# Screenshot saved via --output-dir or returned in response

Security Notes

  • By default restricts file system access to workspace root
  • Host validation prevents navigation to untrusted domains
  • Sandboxing enabled by default (use --no-sandbox with caution)
  • Service workers blocked by default

Troubleshooting

# Update browsers
npx playwright install chromium

# Debug mode
npx @playwright/mcp --headless=false --output-mode=stdout

# Check installation
playwright-mcp --version

Links

Security Scan

OpenClaw

gpt-5-mini

clean

OpenClaw 分析

The skill's requested binaries, install method, and runtime instructions align with a Playwright MCP browser-automation tool; nothing in the package or SKILL.md is obviously inconsistent, but the npm-sourced install and lack of a homepage/author metadata leave some supply-chain uncertainty.

置信度: medium

VirusTotal

Type: OpenClaw Skill Name: playwright-mcp Version: 1.0.0 The OpenClaw AgentSkills skill bundle for 'playwright-mcp' is classified as benign. The `SKILL.md` file provides clear documentation for browser automation using Playwright MCP, including installation instructions and usage examples, without any evidence of prompt injection attempts or instructions for malicious actions. It even highlights built-in security features like host validation and restricted file system access. The `examples.py` script is a conceptual demonstration of the skill's usage and does not perform any actual harmful operations, using `example.com` as a placeholder and explicitly stating its conceptual nature. There is no indication of data exfiltration, persistence, or other malicious intent across any of the files.

元数据

  • 作者: @spiceman161
  • 创建时间: 2026/02/08
  • 更新时间: 2026/02/26
  • 版本数: 1
  • 评论数: 2
  • 扫描时间: 2026/02/11

运行要求

  • os:linux
  • os:darwin
  • os:win32
Playwright MCP | ClawHub 中文站