Playwright Skill gives an agent a small executor and helper library for browser automation. The agent writes a focused Playwright script for your request, runs it through run.js and reports what happened, with screenshots and console output.
It finds running dev servers on localhost, opens a visible browser by default, and covers responsive checks, login flows, link checks, network interception and attaching to an existing Chrome session. A full API reference loads only when a task needs it.
What You Get
- A run.js executor that runs script files or inline snippets with Playwright resolved
- A helper library for dev-server detection, browser launch, contexts, cookie banners and screenshots
- A step-by-step workflow with locator guidance and a rule to confirm the page before claiming success
- An API reference covering network interception, authentication state, video, device emulation and CI patterns
Common Use Cases
- Test a local site after a change and capture screenshots
- Check a layout at desktop and mobile viewport sizes
- Run a login flow with test credentials and verify the dashboard
- Find broken links or check that images load
- Fill and submit a form to see how validation behaves
What Makes It Unique
The skill treats the script as the product. Scripts can be kept and rerun by setting a save folder, dev-server detection picks the local URL for you, and the browser is visible by default so you can watch. The README points to Microsoft’s playwright-cli and playwright-mcp for simple interactive browsing and positions this skill for cases where the automation code itself is worth keeping.
Under The Hood
SKILL.md allows the agent to run node and npm commands and to read and write files. First setup runs npm install and downloads Playwright and Chromium over the network. The agent then writes scripts to your temp folder, or to a folder you choose, and runs them with run.js, which starts a Node child process with the skill’s modules on the path. The browser it launches can open any URL you give it, including localhost sites, and the dev-server helper checks local ports for running servers. The skill can also attach to an existing Chrome session with remote debugging, which shares that browser’s cookies, and it warns against using that for secrets unless you ask. Test credentials are read from environment variables you provide.