How to Capture Product Page Screenshots Behind an Age Verification Prompt
Capture the age prompt as it appears, or document product content after completing the site’s authorized verification flow.
To capture a product page behind an age verification prompt, screenshot the browser state you are authorized to view. If the prompt is blocking the page, capture the prompt as it appears. To capture the product content, complete the site’s own verification flow first, then take the screenshot. A screenshot records what the browser can display; it does not grant access to gated content.
This guide shows manual and Playwright methods, how to choose a capture scope, and how to keep the screenshot useful as evidence. It does not cover bypassing an age check, falsifying age information, or removing the gate to expose restricted content.
Choose what the screenshot needs to show
First decide what question the image must answer. A screenshot of the visible prompt can document its appearance. A screenshot after authorized verification can document the accessible product page.
| Capture scope | Use it for | Trade-off |
|---|---|---|
| Viewport | The prompt or page as visible in the current browser window | Does not include content below the viewport |
| Element | A specific visible prompt, product card, or page region | Excludes surrounding context outside the selected element |
| Full page | The complete scrollable page available to the authorized session | May be tall; content that remains gated will not appear |
Use a screenshot when visual layout matters. If you need readable page structure or text, an accessibility snapshot is a better fit than an image. Playwright documents viewport, element, and full-page screenshot options, and distinguishes screenshots from accessibility snapshots in its [Playwright MCP documentation](https://github.com/microsoft/playwright-mcp) and [Page screenshot API](https://playwright.dev/docs/api/class-page#page-screenshot).
Manual capture: record the prompt or authorized page
- Open the product page in a browser session you are authorized to use.
- Choose the state to document. Leave the age prompt visible if the prompt itself is the subject. If you need the product content, complete the site’s own verification process with accurate information and only where authorized.
- Set the browser window to the viewport size relevant to your record.
- Use the browser’s built-in screenshot command or operating-system capture shortcut. Save the image in a lossless format such as PNG when legibility matters.
- Keep a note of the page URL, date and time, browser, viewport dimensions, and whether the capture shows the prompt or the post-verification page.
The extra notes make the image easier to interpret later. They are practical documentation guidance, not a claim that a particular platform requires these fields.
Automate with Playwright
Playwright’s Page screenshot API supports viewport and full-page captures, element screenshots, output path and image type, scale, and clipping. Install Playwright and its browser using the official [Playwright installation guide](https://playwright.dev/docs/intro). The examples below use a page that remains at the visible prompt; they do not interact with or defeat the age gate.
JavaScript: save the visible viewport
import { chromium } from 'playwright';
const url = 'https://example.com/product';
const browser = await chromium.launch({ headless: true });
const page = await browser.newPage({ viewport: { width: 1440, height: 1000 } });
try {
await page.goto(url, { waitUntil: 'domcontentloaded', timeout: 30000 });
await page.screenshot({ path: 'age-prompt.png', type: 'png' });
} finally {
await browser.close();
}
Replace the example URL with a page you are authorized to visit. This captures the current viewport. The finally block closes the browser even when navigation or capture fails.
Capture a full page or a visible element
// Full scrollable page available to this session
await page.screenshot({ path: 'page-full.png', fullPage: true, type: 'png' });
// A visible element, such as the prompt container
const prompt = page.locator('[role="dialog"]').first();
await prompt.screenshot({ path: 'prompt.png', type: 'png' });
Replace [role="dialog"] with a selector that matches the page’s actual markup. If there is no matching element, inspect the page’s accessible structure or use a viewport screenshot. An element screenshot captures the selected element; full-page capture covers the scrollable page. The Playwright MCP screenshot tool does not combine an element target with full-page capture. See the [Playwright MCP tool documentation](https://github.com/microsoft/playwright-mcp) and [screenshot API options](https://playwright.dev/docs/api/class-page#page-screenshot).
Python: save the visible viewport
from playwright.sync_api import sync_playwright
url = "https://example.com/product"
with sync_playwright() as p:
browser = p.chromium.launch(headless=True)
page = browser.new_page(viewport={"width": 1440, "height": 1000})
try:
page.goto(url, wait_until="domcontentloaded", timeout=30_000)
page.screenshot(path="age-prompt.png", full_page=False)
finally:
browser.close()
To capture the scrollable page, set full_page=True. To capture an element, locate it and call its screenshot method:
prompt = page.locator('[role="dialog"]').first
prompt.screenshot(path="prompt.png")
cURL
cURL requests a URL but does not render a browser page or execute a site’s client-side interface. It cannot faithfully screenshot an age prompt. Use it to retrieve the page response for inspection, if that is useful and authorized, or use a browser capture method for the screenshot.
curl --location --max-time 30 \
--output product-page-response.html \
'https://example.com/product'
Keep the capture faithful and useful
- Do not bypass the gate. If the prompt blocks the content, capture the prompt. Access content only through the site’s authorized flow.
- Match the capture to the question. Use a viewport for what a visitor sees at a given window size, an element for a focused component, and full-page for the scrollable page the session can access.
- Preserve context. Keep the URL and capture time with the file. If the image may be reviewed later, note browser and viewport settings too.
- Separate visual evidence from text extraction. Use an accessibility snapshot when you need structure or text; do not assume the screenshot contains machine-readable text.
- Respect access and use limits. The sources here describe screenshot functionality; they do not establish a general legal right to access or reproduce every product page. Requirements can vary by jurisdiction and use.
Performance, reliability, and cost
A manual screenshot has little setup and is useful for a one-off record, but the result depends on the window size and state at capture time. Automation makes repeated captures more consistent when you fix the viewport and use the same capture scope. Navigation can still time out or return before a client-rendered prompt appears; wait for a known, visible page condition when you can identify one, and keep a bounded timeout.
Full-page captures can produce much taller files than viewport captures. Choose PNG when fine text or interface details need to remain crisp; consider JPEG when smaller files matter and some compression is acceptable. These are general format trade-offs, not a benchmark for a particular page. Browser automation has no per-shot service charge, but it requires a runtime, browser installation, and maintenance of the script and environment.
Troubleshooting
| Symptom | Likely cause | Fix |
|---|---|---|
| Screenshot is blank or only partly rendered | Capture ran before the page UI appeared, or navigation ended before client rendering finished | Wait for a stable, visible element that belongs to the page, or use a short bounded wait. Keep the timeout finite. |
| Navigation times out | The page or its resources did not reach the selected readiness condition in time | Try domcontentloaded for initial HTML, increase the timeout modestly, and capture the visible state if the prompt is already present. Do not wait indefinitely for every network request. |
| Element locator finds nothing | The selector does not match this page, or the prompt uses different markup | Inspect the page structure and use a selector that identifies the intended visible element. Fall back to a viewport capture when a stable selector is unavailable. |
| Full-page shot omits gated product content | The browser session has not been granted access to that content | Capture the visible gate, or complete the authorized verification flow and capture the resulting page. Full-page capture does not grant access. |
| Text is hard to read in the image | The viewport is too small, the image was scaled down, or a lossy format blurred details | Capture at a suitable viewport and preserve the original image. Use PNG for crisp interface text. |
| cURL output is HTML, not an image | cURL fetched a response body; it did not render the browser interface | Use Playwright or a browser screenshot service for a rendered screenshot. |
Or skip the browser setup
ScreenshotNeo is a website screenshot API and MCP server. One GET request returns an image or PDF; its [API documentation](https://screenshotneo.com/docs/) lists the available parameters.
curl -G "https://api.screenshotneo.com/v1/shot" \
-d access_key=YOUR_API_KEY \
--data-urlencode url=https://example.com/product \
-o product-page.webp
import requests
r = requests.get(
"https://api.screenshotneo.com/v1/shot",
params={"access_key": "YOUR_API_KEY", "url": "https://example.com/product"},
timeout=90,
)
open("product-page.webp", "wb").write(r.content)
const q = new URLSearchParams({
access_key: 'YOUR_API_KEY',
url: 'https://example.com/product'
});
const res = await fetch(`https://api.screenshotneo.com/v1/shot?${q}`);
if (!res.ok) throw new Error(`Screenshot request failed: ${res.status}`);
await Bun.write('product-page.webp', res);
ScreenshotNeo accepts cookie and consent banners, then removes more than 60 known consent platforms, newsletter popups, and chat widgets before capture; each step can be turned off. A screenshot API still records only what its browser can access: it does not authorize entry through an age gate. Use a site’s authorized verification flow when the content is gated. Bot checks, blank pages, failed loads, timeouts, and cache hits are not billed, and response headers say which page verdict occurred and whether it was billed. Its MCP server offers take_screenshot, get_page_info, and capture_pdf for AI agents. The free plan includes 1,000 screenshots per month with no card; paid plans start at $5 for 3,000 screenshots.
Sign up for 1,000 free screenshots a month, with no card required.
FAQ
Can I screenshot the age verification prompt without passing it?
Yes, if the prompt is visible in the browser session. The image documents that visible state; it does not authorize access to the gated product content.
Will full-page capture include content below an age prompt?
Only content available to that browser session can be captured. If the gate prevents the page from rendering, the screenshot will show the gate rather than hidden content.
Does an age-verification rule work the same everywhere?
No single rule should be assumed to apply universally. The European Commission describes an EU approach for proving eligibility to access legally age-restricted sites, initially for over-18 access; its stated feature-ready date was 15 April 2026. That is EU-specific context, not a universal rule. The FTC’s February 2026 COPPA policy statement is also narrow: it concerns certain general- or mixed-audience operators using personal information solely to determine age, subject to conditions. It is not blanket approval of every age-check method. See the [European Commission overview](https://digital-strategy.ec.europa.eu/en/policies/eu-age-verification) and [FTC statement](https://www.ftc.gov/news-events/news/press-releases/2026/02/ftc-announces-coppa-policy-statement-age-verification).
Is an age-gate plugin needed to take a screenshot?
No. An age-gate plugin is for site operators implementing a gate. A browser screenshot or authorized browser automation session is the relevant tool for recording what a visitor can see.


