playwright-mcp
Browser automation via Playwright MCP server. Navigate websites, click elements, fill forms, extract data, take screenshots, and perform full browser automation workflows.
Why use this skill?
Control Chrome, Firefox, or WebKit with Playwright MCP. Navigate, fill forms, extract data, take screenshots, and automate browser workflows. Install now!
Install via CLI (Recommended)
clawhub install openclaw/skills/skills/spiceman161/playwright-mcpWhat This Skill Does
The Playwright MCP skill provides powerful browser automation capabilities directly within your OpenClaw environment. Leveraging the Playwright MCP server, this skill allows you to programmatically control web browsers (Chrome, Firefox, or WebKit) to perform a wide range of tasks. You can navigate to any URL, interact with web elements by clicking buttons, filling out forms with text, and selecting options from dropdowns. Beyond interaction, it excels at data extraction, enabling you to retrieve text content from specific elements or execute custom JavaScript on a page to pull structured data. For visual context or debugging, you can capture screenshots and obtain page snapshots. The skill also supports advanced features like uploading files, simulating keyboard presses, and closing browser contexts when done. It's designed for building sophisticated browser automation workflows, from simple data scraping to complex multi-step interactions.
Installation
To install the Playwright MCP skill, use the following command in your OpenClaw environment:
clawhub install openclaw/skills/skills/spiceman161/playwright-mcp
If this is your first time using Playwright, you may need to install the browser binaries. Run the following command:
npx playwright install chromium
(Replace chromium with firefox or webkit if you intend to use those browsers).
Use Cases
This skill is ideal for a variety of automation tasks:
- Web Scraping: Extracting data from websites, such as product prices, article content, or table data, even from dynamic pages.
- Form Submission: Automating the process of filling out and submitting web forms, such as login forms, registration pages, or contact forms.
- Automated Testing: Simulating user interactions to test web application functionality.
- Data Entry: Populating online forms with data from external sources.
- Report Generation: Navigating to specific web pages, extracting key information, and compiling it into reports.
- Workflow Automation: Chaining multiple browser actions to automate complex online processes.
Example Prompts
- "Navigate to
https://example.com/productsand extract the text content of all elements with the classproduct-name." - "Fill out the login form on
https://example.com/loginwith usernametestuserand passwordsecurepass, then click the submit button and retrieve the text from the element with selector.welcome-message." - "Open
https://example.com/uploadand upload the file located at/path/to/my/document.pdfusing the file input with the IDfile-input."
Tips & Limitations
- Headless Operation: For faster and non-interactive execution, consider starting the Playwright MCP server in headless mode using the
--headlessflag. This is ideal for server environments or automated scripts. - Browser Choice: While Chromium is default, you can specify
firefoxorwebkitusing the--browseroption for compatibility testing or specific needs. - Viewport Size: For consistent layout rendering, especially when taking screenshots or extracting visual data, set a specific viewport size with
--viewport-size(e.g.,1280x720). - Error Handling: Be mindful of potential network errors or element-not-found issues. Implement robust error handling in your prompts, potentially using
browser_evaluateto check for conditions before proceeding. - Security: Be cautious when navigating to untrusted websites or interacting with sensitive forms. Utilize
--allowed-hostsand--blocked-originsoptions for enhanced security if needed. Avoid running the server with--ignore-https-errorsunless absolutely necessary and you understand the risks. - Dynamic Content: Websites that heavily rely on JavaScript for content loading might require using
browser_evaluatewith custom scripts to ensure data is captured after the page has fully rendered and updated. - Resource Usage: Running multiple browser instances or complex automation can consume significant system resources (CPU, RAM). Monitor your system's performance.
Metadata
Not sure this is the right skill?
Describe what you want to build — we'll match you to the best skill from 16,000+ options.
Find the right skillPaste this into your clawhub.json to enable this plugin.
{
"plugins": {
"official-spiceman161-playwright-mcp": {
"enabled": true,
"auto_update": true
}
}
}Tags(AI)
Flags: network-access, file-write, code-execution
Related Skills
playwright-browser-automation
Browser automation using Playwright API directly. Navigate websites, interact with elements, extract data, take screenshots, generate PDFs, record videos, and automate complex workflows. More reliable than MCP approach.
sys-updater
System package maintenance for Ubuntu (apt), npm, brew, and OpenClaw skills. Conservative workflow with 2-day quarantine for non-security updates, automatic security updates, and scheduled reviews with web search for bug assessment.