playwright-screenshot

Capture full-page and element screenshots of web pages using Playwright.

1|Updated Jun 17, 2026
One-click install
npx skills add https://github.com/Tcuzzo/HydraAgent_public --skill playwright-screenshot-tcuzzo
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: playwright-screenshot
Source: https://github.com/Tcuzzo/HydraAgent_public/tree/main/hydra/schemes/bundles/web-testing/skills/playwright-screenshot
Command: npx skills add https://github.com/Tcuzzo/HydraAgent_public --skill playwright-screenshot-tcuzzo

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill requires @playwright/test.

What problem does it solve? Capturing accurate screenshots of web pages is harder than it looks: lazy-loaded content, sticky headers, animations, and responsive layouts all cause incomplete or misleading captures. This Skill provides a structured Playwright workflow that handles these pitfalls so screenshots are complete and reproducible. ## Core Features & Use Cases - Full-Page Capture: Scrolls through pages to trigger lazy loading, waits for network idle, and captures below-the-fold content with fullPage: true. - Element Screenshots: Locates specific elements by selector and captures them with configurable padding for bug reports and visual evidence. - Device Emulation: Emulates mobile viewports (e.g., iPhone 14 Pro at 393x852 with device scale factor 3) for responsive layout verification. - Use Case: A QA engineer needs visual evidence of a checkout bug. The Skill navigates to the page, waits for dynamic content, captures the error banner element with padding, and saves an annotated screenshot with timestamp and viewport metadata. ## Quick Start Capture a full-page screenshot of the checkout page at desktop viewport and save it with a timestamped filename.

Frequently Asked Questions about playwright-screenshot

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I take a full-page screenshot with Playwright?▼

Use the screenshot method with the fullPage: true option after navigating to the page. Wait for network idle first and scroll through the page to trigger lazy-loaded content so the capture includes everything below the fold.

How to screenshot a specific element in Playwright?▼

Locate the element with a CSS selector such as .form-error-banner, then call the element's screenshot method with a padding option to add surrounding space. This produces a focused capture useful for bug reports and visual evidence.

Does Playwright support mobile viewport emulation for screenshots?▼

Yes, Playwright emulates devices like iPhone 14 Pro by setting viewport size, device scale factor, user agent, and touch events. This lets you capture screenshots that accurately reflect mobile rendering.

Why is my Playwright screenshot blank or incomplete?▼

Blank screenshots usually mean the page had not finished loading when captured. Increase wait time, wait for network idle, verify the URL, and scroll to trigger lazy-loaded images before capturing.

How do I handle sticky headers duplicating in full-page screenshots?▼

Sticky headers and footers can repeat across a full-page capture. Use the clip option to exclude overlapping regions, or hide fixed-position elements via CSS before taking the screenshot.