Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

To capture a website’s regional cookie banner reliably, start with a fresh browser context, reproduce the regional signals the site actually uses, and save a screenshot before clicking anything. Playwright can emulate browser geolocation, but that alone does not make the request come from that country: sites may instead rely on network location or stored consent preferences. Record those conditions with the image so the result can be reproduced.

Decide what the screenshot needs to show

Choose the capture state before configuring the browser. A first-visit banner, a page after rejecting cookies, and an unobstructed page are different evidence; one image cannot stand in for all three.

  • Untouched banner: Capture before interacting if you need to document what a visitor sees initially.
  • Consent outcome: Click the site’s actual accept, reject, or preferences control, then capture the resulting state. A clean-looking image does not prove the site recorded a choice.
  • Page content: Capture the viewport, the banner element, or the full page depending on what needs to be visible. Playwright documents all three screenshot approaches; its documented tool interface does not combine a target element with full-page capture. Playwright screenshot documentation.

Reproduce the regional conditions

First identify which regional signals might matter for the target site. Browser geolocation, language or locale, timezone, and network egress are separate settings, not substitutes for one another. Changing a language setting alone does not establish that you have reproduced a country-specific banner. Regional cookie behavior and implementations can vary; the cited 2025 study discusses that variation without establishing how any particular site selects its region. “Navigating Cookie Consent Violations Across the Globe”.

Use geolocation when the site requests browser location

Playwright lets you set coordinates and grant the geolocation permission on a browser context. This emulates the browser location API; it does not change the network origin of the request. If the site appears to use IP-based location, use an authorized network route in the target region and record it. Playwright documents the geolocation permission and coordinates in its Emulation guide.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Start with clean consent state

For first-visit behavior, create a fresh context rather than reusing cookies or local preferences that could suppress the banner. If you do reuse a saved state, document it. The target site’s storage mechanism is not established in advance, so inspect the actual site rather than assuming where it saves a choice.

Capture the banner with Playwright

Install Playwright and its browser once in your project with npm init -y, then npm install playwright, then npx playwright install chromium. Save the following as regional-banner.mjs. It creates a new context, grants geolocation permission, sets coordinates, loads the page, and saves a viewport screenshot before any consent control is clicked.

import { chromium } from 'playwright';

const url = process.env.URL;
if (!url) throw new Error('Set URL to the page you want to capture.');

// Use coordinates appropriate to your authorized test region.
const browser = await chromium.launch({ headless: true });
const context = await browser.newContext({
  viewport: { width: 1440, height: 1000 },
  geolocation: { latitude: 48.8566, longitude: 2.3522 },
  permissions: ['geolocation'],
});
const page = await context.newPage();

try {
  await page.goto(url, { waitUntil: 'domcontentloaded', timeout: 60000 });
  // Give client-rendered consent UI time to appear; adjust for the site.
  await page.waitForTimeout(1500);
  await page.screenshot({ path: 'banner-first-visit.png' });
} finally {
  await context.close();
  await browser.close();
}

Run it with URL='https://example.com' node regional-banner.mjs, replacing the example URL with the page under test. The coordinates in the sample are an example location, not a guarantee that the site will show a particular regional banner.

Capture a banner element or the full page

Once you have inspected the page and identified a stable selector, use an element screenshot for a focused record. For a full-page capture, use fullPage: true instead; do not combine it with an element screenshot.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
// Focused capture, using a selector verified on the target site:
const banner = page.locator('[data-testid="cookie-banner"]');
await banner.waitFor({ state: 'visible', timeout: 10000 });
await banner.screenshot({ path: 'banner-element.png' });

// Alternatively, capture the whole scrollable page:
await page.screenshot({ path: 'full-page.png', fullPage: true });

The selector above is illustrative: consent interfaces are site-specific, so replace it with one that exists on the page. Playwright also supports screenshot filename, output type, and pixel scale options; consult its screenshot reference for the documented interface.

Record a consent action as a separate state

For a consent-flow test, interact with the actual labeled control matching the intended choice, wait for the site to update, and save a second screenshot. Do not hide the banner with CSS or remove its element and treat that as consent.

// Example only: confirm the button's accessible name on the target site.
await page.getByRole('button', { name: 'Reject all' }).click();
await page.waitForTimeout(500);
await page.screenshot({ path: 'after-rejecting.png' });

Button text and behavior vary by site; use the control that truly corresponds to the outcome you intend to document. Browserless also documents a hosted workflow for detecting and clicking consent controls before a screenshot, but its selector logic is service-specific. Browserless cookie-consent example.

#1 Best Overall
HP OmniBook 3 17.3 inch Laptop PC, FHD Display, AMD Ryzen 3 30, 8 GB RAM, 512 GB SSD, AMD Radeon 610M Graphics, Windows 11 Home, Mica Silver, 17-dp0199nr
  • FULL HD IPS DISPLAY - Enjoy vibrant, crystal-clear images with 178-degree wide-viewing angles
  • AMD RYZEN 3 30 PROCESSOR - Everyday performance you can count on; Multitask, stream, game casually, and edit photos smoothly with responsive power and vibrant HDR visuals
  • ENJOY UP TO 14 HOURS AND 15 MINUTES OF BATTERY LIFE - HP Fast Charge restores battery from 0 to 50% in approximately 45 minutes
  • AMD RADEON 610M GRAPHICS - Experience smooth entertainment; Built for streaming and multitasking, enjoy realistic visuals and efficient performance for work and play
  • STORAGE AND MEMORY - 512 GB PCIe NVMe M.2 SSD offers fast speed and efficient storage; and 8 GB LPDDR5 RAM memory boosts performance with higher bandwidth

Make the capture reproducible

Keep a short record alongside each image. It lets another person distinguish a first-visit screenshot from a post-consent state and reproduce the conditions.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
  • Page URL and capture timestamp
  • Browser and browser version
  • Viewport dimensions and whether the image is viewport, element, or full-page
  • Geolocation coordinates and whether the browser permission was granted
  • Locale, timezone, or network region settings used, when relevant
  • Whether the context was fresh or restored, and the consent action taken, if any

Troubleshoot missing or unexpected banners

No banner appears

Check that the browser context is fresh and that no cookies or local preferences have been restored. Confirm that the site has finished rendering its consent interface. If the site uses network location rather than the browser location API, geolocation coordinates alone will not reproduce the network region.

Rank #2
HP 14" HD Chromebook Laptop for Students, Intel Quad-Core N4120(> N4020), 4GB RAM, 64GB eMMC, WiFi, Webcam, HDMI, USB-A&C, 14 Hours Battery Life, Zoom, Chrome OS, CUE Accessories
  • Intel Celeron N4120: 4 Cores & Threads, 1.1GHz Base Clock, Up to 2.6GHz Boost Clock, 4MB Cache, Intel UHD Graphics 600. The perfect combination of performance, power consumption, and value helps your device handle multitasking smoothly and reliably with four processing cores to divide up the work.

The wrong regional variant appears

Verify which regional signal the site uses instead of changing language alone. Browser location, locale, timezone, and network egress are independent inputs; record the combination you tested. The site’s exact region-selection logic must be established from its behavior, not inferred from one screenshot.

The banner is cut off or absent from the image

Use a viewport size that exposes it, wait for the banner element to become visible, or capture that element directly. If you need page content below the fold, switch to full-page capture rather than assuming a viewport image contains it.

The page looks clean but consent is uncertain

A hidden banner is not evidence of a recorded choice. Use the site’s labeled accept, reject, or manage-preferences action, then capture the updated state and note the action.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Or skip the browser setup

ScreenshotNeo can return a screenshot or PDF with one GET request. For an image capture, request a URL like this:

Rank #3
Sale
AKCHART 15.6'' AI Laptop with Office 365 12GB RAM 256GB SSD Win 11 Laptops
  • Stunning 15.6" FHD IPS Display: Experience crisp 1920x1080 resolution on this 15.6 inch laptop with an IPS panel that delivers wide viewing angles and vivid colors. The narrow-bezel design maximizes screen real estate for comfortable viewing on this Win 11 laptop, whether you're studying or working.
  • Celeron J4105 Processor & 256GB SSD: Powered by a reliable Celeron J4105 processor paired with 12GB DDR4 memory and a fast 256GB M.2 SSD. This laptop computer supports SSD expansion up to 2TB and TF card expansion up to 1TB, so your storage grows with your needs. Delivers smooth multitasking for daily productivity.
  • AI-Powered Win 11 Laptop: Built-in AI features enhance your productivity with smart assistance for writing, summarizing, and task management. Pre-installed with Win 11 and includes Office 365 subscription. This student laptop is backed by 1-year warranty and 24/7 customer support.
  • All-Day 7000mAh Battery & 180° Hinge: The high-capacity 7000mAh battery keeps this laptop powered through long classes or meetings. The 180-degree lay-flat hinge lets you share your screen effortlessly during presentations. This durable laptop computer adapts to your dynamic workflow.
  • Versatile Connectivity Hub: Equipped with USB 3.2, Type-C, Mini HDMI, and 3.5mm audio jack to connect all your peripherals. Stay online anywhere with high-speed 5G WiFi and Bluetooth 4.2. This college laptop keeps you connected at home, in the library, or on the go.
curl -G "https://api.screenshotneo.com/v1/shot" -d access_key=YOUR_API_KEY --data-urlencode url=https://example.com -o shot.webp

See the ScreenshotNeo documentation for API options. Its clean-shot flow accepts cookie/consent banners like a visitor and removes more than 60 known consent platforms, newsletter popups, and chat widgets before capture; each step can be turned off. Bot checks, blank pages, timeouts, failed loads, and cache hits are not billed, and response headers report the page verdict and billing status. An MCP server provides screenshot tools for AI agents. The Free plan includes 1,000 shots per month with no card; paid plans start at $5 for 3,000 shots.

Sign up for ScreenshotNeo’s free plan to try 1,000 screenshots a month with no card.

Independent reader supportYour contribution helps us test, update, and keep practical guides available for everyone.Support on Ko-Fi

Frequently Asked Questions

Does setting Playwright geolocation make the request come from that country?

No. It emulates browser geolocation only; it does not change the request’s network origin.

Free tools Windows power users keep installed

One-click scans. No signup required.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
Rank #4
HP Essential Laptop 2026, Intel CPU, 128GB Storage, Office 365, Windows 11
  • Efficient Performance for Everyday Computing: Powered by Intel N150 processor with up to 3.6 GHz Intel Turbo Boost Technology, 6 MB L3 cache, 4 cores, and 4 threads, this HP laptop delivers responsive performance for web browsing, streaming, document editing, and multitasking. Paired with 4GB LPDDR5 RAM and 128GB UFS storage, it handles daily tasks smoothly. Includes 1-year Microsoft 365 Personal subscription for Word, Excel, PowerPoint, and cloud storage to maximize your productivity.
  • 14-Inch HD Micro-Edge Display:Enjoy clear visuals on the 14-inch HD (1366 x 768) anti-glare screen with 250-nit brightness and 62.5% sRGB coverage. The micro-edge bezel delivers a 79% screen-to-body ratio in a compact design. An HP True Vision 720p HD camera with noise reduction and dual-array microphones supports clear video calls, remote work, and online learning.
  • Modern Connectivity and Wireless Technology: Stay connected with Wi-Fi 6 (2x2) for faster wireless speeds and Bluetooth 5.4 for seamless pairing with accessories. Versatile port selection includes 1 USB Type-C 10Gbps with DisplayPort 1.2 for external displays, 2 USB Type-A 5Gbps ports for peripherals, 1 HDMI 1.4b port, 1 headphone/microphone combo jack, and 1 multi-format SD media card reader. Connect monitors, transfer files quickly, and expand your workspace with ease.
  • All-Day Battery Life and Portable Design: Enjoy up to 11 hours of video playback, 7.5 hours of mixed usage, or 7.5 hours of wireless streaming on a single charge, perfect for students and professionals on the go. Weighing just 3.24 lb and measuring 12.76" x 8.86" x 0.71", this lightweight laptop fits easily in backpacks and bags. The stylish willow green top cover with matte finish and natural silver keyboard deck with vertical brushing pattern offer a modern, professional look.
  • AI-Enhanced Productivity: Access Microsoft Copilot instantly with the dedicated Copilot key for faster assistance. AI Noise Reduction filters background sounds and improves voice clarity during calls. Dual speakers provide clear audio, while the full-size natural silver keyboard and HP Imagepad support comfortable typing and navigation.

Can a screenshot prove that a website recorded consent?

No. The image shows a visual state; document the actual consent control used and the resulting state separately.

Best Value
Sale
HP 14 Laptop, 2027 Edition, Intel N150 CPU, 4GB RAM, 128GB SSD, 1TB Cloud Storage, Long Battery Life, Copilot AI, Windows 11 with Microsoft 365
  • 【Versatile Connectivity】Stay connected with multiple ports including USB 3.0 Type-C, USB 3.0 Type-A, and a headphone/mic combo jack, with Wi-Fi and Bluetooth for seamless wireless networking.

Product prices and availability are accurate as of the date/time indicated and are subject to change. Any price and availability information displayed on Amazon at the time of purchase will apply.