Playwright Skill
tech-leads-club/agent-skills
Complete browser automation with Playwright. An agent skill from tech-leads-club/agent-skills.
Complete browser automation with Playwright. An agent skill from lackeyjb/playwright-skill.
$ npx skills add lackeyjb/playwright-skill --skill playwright-skill -a claude-codeProject install by default; add -g for ~/.claude/skills/.
$ gh skill install lackeyjb/playwright-skill playwright-skill --agent claude-codeProject scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).
$ git clone --depth 1 https://github.com/lackeyjb/playwright-skill.git skills-src && mkdir -p .claude/skills && cp -r skills-src/skills/playwright-skill .claude/skills/playwright-skill && rm -rf skills-srcUse ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.
Claude Code skills documentation · loads skills from .claude/skills/
Install the "playwright-skill" agent skill from https://github.com/lackeyjb/playwright-skill/tree/main/skills/playwright-skill into .claude/skills/playwright-skill/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "playwright-skill", then confirm the skill loads.Claude Code copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$skill-installer install https://github.com/lackeyjb/playwright-skill/tree/main/skills/playwright-skillType this inside Codex. $skill-installer <name> installs a curated skill from openai/skills. The installer writes to $CODEX_HOME/skills (default ~/.codex/skills). Restart Codex if the skill does not show up.
$ npx skills add lackeyjb/playwright-skill --skill playwright-skill -a codexProject install goes to .agents/skills/; add -g for ~/.codex/skills/.
$ gh skill install lackeyjb/playwright-skill playwright-skill --agent codexProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/lackeyjb/playwright-skill.git skills-src && mkdir -p .agents/skills && cp -r skills-src/skills/playwright-skill .agents/skills/playwright-skill && rm -rf skills-srcUse ~/.agents/skills/ instead of .agents/skills for a personal install.
Codex skills documentation · loads skills from .agents/skills/
Install the "playwright-skill" agent skill from https://github.com/lackeyjb/playwright-skill/tree/main/skills/playwright-skill into .agents/skills/playwright-skill/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "playwright-skill", then confirm the skill loads.Codex copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ npx skills add lackeyjb/playwright-skill --skill playwright-skill -a cursorProject install goes to .agents/skills/; add -g for ~/.cursor/skills/.
$ gh skill install lackeyjb/playwright-skill playwright-skill --agent cursorProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/lackeyjb/playwright-skill.git skills-src && mkdir -p .cursor/skills && cp -r skills-src/skills/playwright-skill .cursor/skills/playwright-skill && rm -rf skills-srcUse ~/.cursor/skills/ instead of .cursor/skills for a personal install.
Cursor skills documentation · loads skills from .cursor/skills/, .agents/skills/, .claude/skills/, .codex/skills/
Install the "playwright-skill" agent skill from https://github.com/lackeyjb/playwright-skill/tree/main/skills/playwright-skill into .cursor/skills/playwright-skill/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "playwright-skill", then confirm the skill loads.Cursor copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ gemini skills install https://github.com/lackeyjb/playwright-skill.git --path skills/playwright-skill--scope user (default) or --scope workspace; --path is the subfolder of the repo that holds the skill; --consent skips the security confirmation prompt.
$ npx skills add lackeyjb/playwright-skill --skill playwright-skill -a gemini-cliProject install goes to .agents/skills/; add -g for ~/.gemini/skills/.
$ gh skill install lackeyjb/playwright-skill playwright-skill --agent gemini-cliProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/lackeyjb/playwright-skill.git skills-src && mkdir -p .gemini/skills && cp -r skills-src/skills/playwright-skill .gemini/skills/playwright-skill && rm -rf skills-srcUse ~/.gemini/skills/ instead of .gemini/skills for a personal install, then run /skills reload.
Gemini CLI skills documentation · loads skills from .gemini/skills/, .agents/skills/
Install the "playwright-skill" agent skill from https://github.com/lackeyjb/playwright-skill/tree/main/skills/playwright-skill into .gemini/skills/playwright-skill/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "playwright-skill", then confirm the skill loads.Gemini CLI copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ gh skill install lackeyjb/playwright-skill playwright-skillInstalls for Copilot at project scope by default; add --scope user for a personal install. Preview a skill first with gh skill preview. Needs GitHub CLI 2.90.0 or later (public preview).
$ npx skills add lackeyjb/playwright-skill --skill playwright-skill -a github-copilotProject install goes to .agents/skills/; add -g for ~/.copilot/skills/.
$ git clone --depth 1 https://github.com/lackeyjb/playwright-skill.git skills-src && mkdir -p .github/skills && cp -r skills-src/skills/playwright-skill .github/skills/playwright-skill && rm -rf skills-srcUse ~/.copilot/skills/ instead of .github/skills for a personal install. Commit .github/skills so cloud agent and code review can use it.
GitHub Copilot skills documentation · loads skills from .github/skills/, .claude/skills/, .agents/skills/
Install the "playwright-skill" agent skill from https://github.com/lackeyjb/playwright-skill/tree/main/skills/playwright-skill into .github/skills/playwright-skill/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "playwright-skill", then confirm the skill loads.GitHub Copilot copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ npx skills add lackeyjb/playwright-skill --skill playwright-skill -a opencodeOpenCode documents no install command of its own. Project install goes to .agents/skills/; add -g for ~/.config/opencode/skills/.
$ gh skill install lackeyjb/playwright-skill playwright-skill --agent opencodeProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/lackeyjb/playwright-skill.git skills-src && mkdir -p .opencode/skills && cp -r skills-src/skills/playwright-skill .opencode/skills/playwright-skill && rm -rf skills-srcUse ~/.config/opencode/skills/ instead of .opencode/skills for a personal install.
OpenCode skills documentation · loads skills from .opencode/skills/, .claude/skills/, .agents/skills/
Install the "playwright-skill" agent skill from https://github.com/lackeyjb/playwright-skill/tree/main/skills/playwright-skill into .opencode/skills/playwright-skill/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "playwright-skill", then confirm the skill loads.OpenCode copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
playwright-skillComplete browser automation with Playwright. An agent skill from lackeyjb/playwright-skill.
Playwright Skill is an agent skill from lackeyjb/playwright-skill. Complete browser automation with Playwright. Auto-detects dev servers, writes reusable test scripts, and supports screenshots, responsive checks, UX validation, login flows, link checks, and arbitrary browser automation. Use when the user wants to test a website, automate browser interactions, validate web functionality, or perform browser-based testing.
Its SKILL.md is about 1.9k tokens, which your agent loads only when the skill is triggered. The skill folder holds 6 other files (for example `API_REFERENCE.md`, `lib/helpers.js` and `package-lock.json`). Compatibility notes: Requires Node.js 20+, npm, and network access on first setup to install Playwright and Chromium.
It sits in Testing & QA, covering Browser testing, Browser automation and Authentication. It works with Playwright. The repository describes itself as: General-purpose Playwright automation for coding agents. The licence is MIT.
6 steps, taken from the first numbered list in SKILL.md.
Read from SKILL.md and the folder at commit dd47a6a. It shows what the files ask for, not the result of running them.
Pre-approves these tools, so the agent can use them without asking each time:
Bash(node:*)Bash(npm:*)ReadWriteFrom allowed-tools in the SKILL.md frontmatter.
Ships script files (JavaScript), which the agent can run.
Shell commands in SKILL.md call:
nodenpmFrom the folder's file list and the shell code blocks in SKILL.md.
No URLs in SKILL.md. Its commands use npm, which can reach the network depending on how they are called.
From URLs in SKILL.md, links to its own repository left out.
Names these keys or tokens, usually read from environment variables:
TEST_PASSWORDFrom names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.
Requires Node.js 20+, npm, and network access on first setup to install Playwright and Chromium.
From compatibility in the SKILL.md frontmatter.
Playwright Skill loads about 1.9k tokens when it runs. Until then it costs about 93 tokens; SKILL.md has 513 words of instructions outside code blocks.
Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.
The automated check found no risky patterns in SKILL.md.
Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); files beside SKILL.md are not scanned.
The full file from lackeyjb/playwright-skill at commit dd47a6a, republished under its MIT licence (© lackeyjb). 513 words, ~1,936 tokens.
.claude/skills/playwright-skill/SKILL.md (or your agent's skills folder). This skill also uses 5 other files; get the full folder from GitHub.Write and execute focused Playwright scripts for the user's request. Prefer the skill's executor and helpers, but use the full Playwright API when needed.
This skill can be installed in several locations, so resolve its directory
first. Set SKILL_DIR to the directory containing this SKILL.md file, then run
the commands below as written:
export SKILL_DIR=<absolute path of the directory containing this SKILL.md>
export TMP_DIR="$(node -p 'require("node:os").tmpdir()')"If shell state does not persist between commands, substitute the literal paths
for $SKILL_DIR and $TMP_DIR in each command instead.
Common installation paths:
~/.claude/plugins/marketplaces/playwright-skill/skills/playwright-skill~/.claude/skills/playwright-skill<project>/.claude/skills/playwright-skillFor localhost work, detect running servers before writing a URL:
node -e "require('$SKILL_DIR/lib/helpers').detectDevServers().then(s => console.log(JSON.stringify(s)))"Use the only result automatically. Ask which URL to use when there are multiple results. Ask for a URL or offer to start a server when none exist.
Write reusable scripts to $TMP_DIR/playwright-test-*.js unless the user
asks to save them in the project. Use PW_SCRIPT_DIR to preserve scripts.
Use a visible browser by default. Use headless: true only when requested
or when the environment has no display.
Put the target URL in a constant or environment variable.
Run scripts with node "$SKILL_DIR/run.js" <script.js>.
Report actions, failures, and artifact paths. Do not claim success without checking the resulting page.
Run once:
cd "$SKILL_DIR" && npm run setupThis installs Playwright and Chromium. Use cd "$SKILL_DIR" && npm run install-all-browsers when Firefox or WebKit is required.
const os = require('node:os');
const path = require('node:path');
const { chromium } = require('playwright');
const targetUrl = process.env.TARGET_URL || 'http://localhost:3000';
const artifactDir = process.env.PW_ARTIFACT_DIR || os.tmpdir();
(async () => {
const browser = await chromium.launch({ headless: false });
try {
const page = await browser.newPage();
await page.goto(targetUrl);
console.log('Page loaded:', await page.title());
await page.screenshot({ path: path.join(artifactDir, 'page.png'), fullPage: true });
} finally {
await browser.close();
}
})();Run it:
node "$SKILL_DIR/run.js" "$TMP_DIR/playwright-test-page.js"For short one-off tasks, use inline execution:
node "$SKILL_DIR/run.js" -e "const browser = await chromium.launch({headless: false}); try { const page = await browser.newPage(); await page.goto('https://example.com'); console.log(await page.title()); } finally { await browser.close(); }"The -e process exits as soon as the snippet settles, so close the browser
inside the snippet.
Prefer locators that describe what a user sees, in this order:
page.getByRole() with an accessible namepage.getByLabel() for form controlspage.getByText() for visible contentpage.getByTestId() when the application provides a test contractActions auto-wait for actionability. Use web-first assertions or a locator's
waitFor() instead of waitForSelector(), fixed sleeps, or networkidle.
await page.getByLabel('Email').fill('test@example.com');
await page.getByRole('button', { name: 'Sign in' }).click();
await page.waitForURL('**/dashboard');
await page.getByRole('heading', { name: 'Dashboard' }).waitFor();{
const os = require('node:os');
const path = require('node:path');
const artifactDir = process.env.PW_ARTIFACT_DIR || os.tmpdir();
const viewports = [
{ name: 'desktop', width: 1440, height: 900 },
{ name: 'mobile', width: 390, height: 844 },
];
for (const viewport of viewports) {
await page.setViewportSize(viewport);
await page.goto(targetUrl);
await page.screenshot({ path: path.join(artifactDir, `${viewport.name}.png`), fullPage: true });
}
}Use test credentials supplied by the user. Never invent or expose real credentials. Verify both the navigation and a post-login element.
await page.goto(`${targetUrl}/login`);
await page.getByLabel('Email').fill(process.env.TEST_EMAIL);
await page.getByLabel('Password').fill(process.env.TEST_PASSWORD);
await page.getByRole('button', { name: /sign in|log in/i }).click();
await page.waitForURL('**/dashboard');
await page.getByRole('heading', { name: /dashboard/i }).waitFor();PW_SCRIPT_DIR=./playwright-tests node "$SKILL_DIR/run.js" "$TMP_DIR/playwright-test-login.js"
PW_ARTIFACT_DIR=./playwright-artifacts node "$SKILL_DIR/run.js" "$TMP_DIR/playwright-test-page.js"PW_SCRIPT_DIR copies file-based scripts before execution and adds a timestamp
when a filename already exists. PW_ARTIFACT_DIR controls helper screenshot
output; the default is the operating system temporary directory.
Start Chrome with remote debugging enabled, then connect with Playwright:
const browser = await chromium.connectOverCDP('http://127.0.0.1:9222');
const page = browser.contexts()[0].pages()[0];This reuses cookies and extensions in that session. Do not use it for secrets unless the user explicitly asks; a connected browser has the user's access.
const helpers = require(`${process.env.PW_SKILL_DIR}/lib/helpers`);
const servers = await helpers.detectDevServers();
const browser = await helpers.launchBrowser('chromium');
const context = await helpers.createContext(browser);
const page = await context.newPage();
await helpers.handleCookieBanner(page);
await helpers.takeScreenshot(page, 'result');Available helpers are detectDevServers, getExtraHeadersFromEnv,
launchBrowser, createContext, handleCookieBanner, and takeScreenshot.
Use Playwright locators and assertions directly for actions, waits, extraction,
authentication, tables, and retries.
PW_BROWSER: chromium, firefox, or webkit for launchBrowser().PW_CHANNEL: installed browser channel such as chrome or msedge.PW_EXECUTABLE_PATH: explicit browser executable path.PW_HEADLESS: true or false; visible mode is the default.SLOW_MO: action delay in milliseconds.PW_HEADER_NAME and PW_HEADER_VALUE: one extra HTTP header.PW_EXTRA_HEADERS: JSON object of extra HTTP headers.PW_SCRIPT_DIR: directory for preserving file-based scripts.PW_ARTIFACT_DIR: directory for helper-generated screenshots.See API_REFERENCE.md for network interception, API mocking, authentication state, video, visual checks, device emulation, and CI patterns.
© lackeyjb, MIT. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file
SKILL.md and 5 other files in skills/playwright-skill of lackeyjb/playwright-skill.
Open the folder on GitHubat commit dd47a6a
Playwright Skill next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.
| Skill | Stars | Used in | Tokens | Auto-check | Licence | Repo updated |
|---|---|---|---|---|---|---|
| Playwright Skill this skilllackeyjb/playwright-skill | 3.2k | — | ~1.9k | Automated safety check: Pass | MIT | |
| Playwright Skilltech-leads-club/agent-skills | 7k | — | ~3.6k | Automated safety check: Pass | Custom licence | |
| Open BrowserJasonHonKL/Openbrowser | 114 | — | ~1.6k | Automated safety check: Pass | MIT | |
| Playwright CLIfugazi/test-automation-skills-agents | 247 | — | ~2.2k | Automated safety check: Pass | MIT | |
| Sap Browser Automationsecondsky/sap-skills | 460 | — | ~3.3k | Automated safety check: Pass | GPL-3.0 | |
| Playwright Testingaehrc/pathling | 137 | — | ~1.5k | Automated safety check: Pass | Apache-2.0 |
tech-leads-club/agent-skills
Complete browser automation with Playwright. An agent skill from tech-leads-club/agent-skills.
JasonHonKL/Openbrowser
A skill your agent uses whenever the task involves browsing web pages, extracting page content, clicking forms, or completing web workflows.
fugazi/test-automation-skills-agents
Drive a live browser from the CLI with playwright-cli to navigate, interact, snapshot, and capture evidence.
secondsky/sap-skills
A skill your agent uses when an agent must inspect or operate an authenticated SAP web UI through an in-app Browser, Microsoft Edge CDP, or an existing Playwright client, especially when SAP SSO…
aehrc/pathling
Expert guidance for writing end-to-end tests with Playwright Test framework.
secondsky/claude-skills
Browser automation and E2E testing with Playwright. An agent skill from secondsky/claude-skills.
Works with
Categories
Complete browser automation with Playwright. An agent skill from lackeyjb/playwright-skill. Playwright Skill is an agent skill from lackeyjb/playwright-skill. Complete browser automation with Playwright.
Playwright Skill fits situations like: the user wants to test a website; automate browser interactions; validate web functionality; perform browser-based testing.
Run `npx skills add lackeyjb/playwright-skill --skill playwright-skill -a claude-code`. Or copy the skill folder (skills/playwright-skill in lackeyjb/playwright-skill) into .claude/skills/playwright-skill in your project. Claude Code loads it when a task matches its description.
Run `npx skills add lackeyjb/playwright-skill --skill playwright-skill -a codex`. Or copy the skill folder (skills/playwright-skill in lackeyjb/playwright-skill) into .agents/skills/playwright-skill in your project. Codex loads it when a task matches its description.
Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add lackeyjb/playwright-skill --skill playwright-skill -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/playwright-skill, .gemini/skills/playwright-skill, .github/skills/playwright-skill and .opencode/skills/playwright-skill in your project.
Going by SKILL.md and its folder, Playwright Skill needs JavaScript for the scripts in its folder, the command-line tools its instructions call (node and npm) and credentials named TEST_PASSWORD. Our summary lists: Node.js. Its frontmatter pre-approves these tools: Bash(node:*), Bash(npm:*), Read, Write. Compatibility (from SKILL.md): Requires Node.js 20+, npm, and network access on first setup to install Playwright and Chromium..
SKILL.md contains no URLs. Its commands use npm, which can reach the network depending on how they are called. This is read from the text; nothing was executed.
Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. Review the folder before installing.
Playwright Skill is published under the MIT licence (declared in SKILL.md). It allows redistribution, so the full SKILL.md is shown on this page.
About 1.9k tokens (SKILL.md is roughly 7.7k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full.
Skills that share tags, products or a category with Playwright Skill: Playwright Skill (tech-leads-club/agent-skills, 7k stars), Open Browser (JasonHonKL/Openbrowser, 114 stars), Playwright CLI (fugazi/test-automation-skills-agents, 247 stars) and Sap Browser Automation (secondsky/sap-skills, 460 stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.
lackeyjb (a GitHub user) maintains it in lackeyjb/playwright-skill, which has 3,174 GitHub stars. The repository was last updated on October 1, 2026.
Source: lackeyjb/playwright-skill on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.