Full browser automation via Playwright MCP — navigate, click, fill forms, screenshot, extract data, and run E2E tests on JS-rendered pages.
npx clawhub@latest install playwrightPlatforms
Playwright (Automation + MCP + Scraper) is a browser automation skill that lets AI agents control real browsers through Playwright MCP or direct Playwright scripts. It handles everything static HTTP fetching cannot: JS-rendered pages, multi-step forms, authentication flows, screenshots, PDFs, file uploads/downloads, and structured data extraction from rendered DOM. Whether you're authoring E2E tests, debugging UI regressions, or driving a browser through MCP tool actions, this skill provides the guidance and patterns to get reliable results.
npx clawhub@latest install playwrightClick the Install button at the top of this page for one-click setup
@playwright/test suite, tracing CI flakes, or reproducing UI bugs in headed mode.browser_* tools in the loop and you want navigate-click-fill-screenshot workflows without writing new automation code.fetch or HTTP skill is faster, cheaper, and less brittle when the page doesn't require JavaScript rendering.Run npx @playwright/mcp --headless to expose browser_navigate, browser_click, browser_type, browser_snapshot, and more as first-class tool actions. This path requires no new automation code — the agent drives the browser directly through MCP tool calls.
Write and run direct Playwright scripts (chromium.launch, page.goto, page.screenshot) or full @playwright/test suites with npx playwright test. Supports headed runs, trace capture, retries, and parallel workers out of the box.
Use npx playwright codegen <url> to record interactions and generate stable locators. Eliminates guessing selectors from source and produces role-, label-, and text-based locators that survive minor DOM changes.
Capture full-page screenshots, generate PDFs, record execution traces, and download files — all through either MCP tool actions or direct Playwright API calls. Artifacts stay local in the workspace or system temp directory.
The skill enforces role, label, text, and test-ID selectors over fragile CSS/XPath, and web-first assertions over raw command checks. Built-in guidance on actionability waits prevents flaky sleep-based timing hacks.
No hidden files, persistent sessions, or undeclared network calls. Auth state is temporary unless explicitly reused. High-stakes production flows require explicit user confirmation before proceeding.
Run and extend an existing @playwright/test suite against a local or staging app. Use npx playwright test --trace on to capture artifacts for CI failures, then diagnose flake with trace viewer and headed re-runs.
Let an agent navigate a site, fill out a multi-step form, and capture a screenshot — all via browser_navigate, browser_type, browser_click, and browser_snapshot MCP actions — without writing a single line of Playwright script.
Navigate to a JS-rendered page, wait for the DOM to settle, then use browser_evaluate or a direct Playwright script to extract structured data. Ideal when the target has no API and the content only appears after JavaScript runs.
Reproduce a reported UI regression in headed mode with npx playwright test --headed, capture a trace with --trace on, and inspect network, console, and DOM snapshots to isolate the root cause before writing a fix.
npx clawhub@latest install playwrightPlatforms
Log in to write a review
No reviews yet. Be the first to share your experience!