Build browser automation and web scraping with Playwright on your local machine. Prevents 10 documented errors including CI timeout hangs, extension testing failures, and Ubuntu compatibility issues. Includes stealth mode for anti-bot bypass, authenticated sessions, infinite scroll handling, screenshot/PDF generation, and v1.57 Speedboard performance analysis. Use when: automating browsers, scraping protected sites, testing with real IPs, bypassing bot detection, generating screenshots/PDFs, or troubleshooting "target closed", "page.pause() hangs CI", "permission prompts block tests", or "Ubuntu 25.10 installation" errors.
View on GitHubskills/playwright-local/SKILL.md
February 1, 2026
Select agents to install to:
npx add-skill https://github.com/brendadeeznuts1111/tier-1380-omega/blob/main/skills/playwright-local/SKILL.md -a claude-code --skill playwright-localInstallation paths:
.claude/skills/playwright-local/# Playwright Local Browser Automation
**Status**: Production Ready ✅
**Last Updated**: 2026-01-21
**Dependencies**: Node.js 20+ (Node.js 18 deprecated) or Python 3.9+
**Latest Versions**: playwright@1.57.0, playwright-stealth@0.0.1, puppeteer-extra-plugin-stealth@2.11.2
**Browser Versions**: Chromium 143.0.7499.4 | Firefox 144.0.2 | WebKit 26.0
> **⚠️ v1.57 Breaking Change**: Playwright now uses [Chrome for Testing](https://developer.chrome.com/blog/chrome-for-testing/) builds instead of Chromium. This provides more authentic browser behavior but changes the browser icon and title bar.
---
## Quick Start (5 Minutes)
### 1. Install Playwright
**Node.js**:
```bash
npm install -D playwright
npx playwright install chromium
```
**Python**:
```bash
pip install playwright
playwright install chromium
```
**Why this matters:**
- `playwright install` downloads browser binaries (~400MB for Chromium)
- Install only needed browsers: `chromium`, `firefox`, or `webkit`
- Binaries stored in `~/.cache/ms-playwright/`
### 2. Basic Page Scrape
```typescript
import { chromium } from 'playwright';
const browser = await chromium.launch({ headless: true });
const page = await browser.newPage();
await page.goto('https://example.com', { waitUntil: 'networkidle' });
const title = await page.title();
const content = await page.textContent('body');
await browser.close();
console.log({ title, content });
```
**CRITICAL:**
- Always close browser with `await browser.close()` to avoid zombie processes
- Use `waitUntil: 'networkidle'` for dynamic content (SPAs)
- Default timeout is 30 seconds - adjust with `timeout: 60000` if needed
### 3. Test Locally
```bash
# Node.js
npx tsx scrape.ts
# Python
python scrape.py
```
---
## Why Playwright Local vs Cloudflare Browser Rendering
| Feature | Playwright Local | Cloudflare Browser Rendering |
|---------|------------------|------------------------------|
| **IP Address** | Residential (your ISP) | Datacenter (easily detected) |
| **Ste