ScreenshotNeo

BlogHow-to

How to save a screenshot of a logged-in page after a consent banner reloads

Keep your session intact, let the page settle, and capture the right view. Learn how to handle a reappearing consent banner safely.

By the ScreenshotNeo team4 October 20268 min read

Keep the logged-in tab and its site data intact. Let the page finish loading, handle the consent banner using the site’s own controls, and then capture the visible viewport or the whole page, depending on what you need. Do not clear cookies or browser storage just to dismiss a banner: cookies can carry session state. A banner appearing again does not by itself show that your login failed, and its persistence depends on the site’s implementation and browser state.

This guide covers a browser-native workflow, how to investigate a reload in Chrome, full-page capture in Firefox, and an API option for developers automating screenshots. The exact controls can vary by browser version and operating system.

1. Capture the intended page state

  1. Keep the existing authenticated tab open. Avoid clearing cookies, local storage, or browser data. HTTP cookies are commonly used for session management and personalization, but a site may store its consent choice in a different way. See Chrome’s cookie documentation and MDN’s cookie guide.
  2. Wait for the page to finish loading. Give delayed content and the consent interface time to appear. If the banner is present, use the site’s accept, reject, or dismiss control according to your intent.
  3. Choose the capture area. Use an ordinary browser or operating-system screenshot for what is currently visible. Use a full-page capture only if content below or above the viewport matters.
  4. Save the image and check it. Confirm the screenshot shows the intended page state and that it does not expose credentials or private account details the recipient does not need.

If this is a record or report, keep relevant timestamp and context separately. A screenshot alone may not establish when or under what conditions the page was captured.

2. Use browser-native screenshot controls

Capture the visible viewport

Once the page has settled, use your browser’s screenshot command or your operating system’s ordinary screenshot function. The operating-system shortcut varies by platform, so use the shortcut documented for the system you are on. Make sure the authenticated page is the active window and that the consent banner is in the state you intend to record.

Capture the entire page in Firefox

Firefox DevTools can capture a full page and save the image to Downloads. Enable Take a screenshot of the entire page in DevTools Settings under Available Toolbox Buttons, then use the screenshot button. Firefox’s command line also supports:

:screenshot page.png --fullpage

See the Firefox screenshot documentation and Firefox DevTools tips. Full-page capture can include content that is not visible in the viewport; review the result for overlays, sticky elements, or private information before sharing.

3. Diagnose a banner that reappears in Chrome

Chrome’s Network panel can capture screenshots at points during page loading. This helps you see when content or a banner appears in relation to network activity. These are diagnostic frames during loading; they are not automatically the same as one final screenshot of the settled page.

  1. Open Chrome DevTools and select the Network panel.
  2. Open Network settings and enable Capture screenshots.
  3. Keep the Network panel focused and reload the page.
  4. Inspect the captured thumbnails alongside the network activity to see when the banner appears.

Chrome documents this feature in its Network panel reference. Use it to investigate the reload timing, then take a regular viewport or full-page screenshot once the desired state is visible.

If you need to inspect session cookies, open DevTools Application > Storage > Cookies and select the site’s origin. Inspection can help diagnose state; deleting or editing cookies just to remove a banner can disrupt the session. Chrome’s cookie guide explains the panel.

4. Automate a capture with an API

Browser-native controls are a good fit for a one-off screenshot of a page already open in your authenticated browser. For automated captures, a screenshot API can request a URL and return an image or PDF. Authentication is the key constraint: a browser session that is already logged in does not automatically transfer to an API request. Use an API only when you can supply the access state through a supported method, such as authorized cookies or headers, and are permitted to do so. Never put credentials in a public URL or share them in a screenshot.

ScreenshotNeo is a website screenshot API and MCP server. Its API accepts cookies, custom headers, and Authorization, and can capture PNG, JPEG, WebP, or PDF. Consult the ScreenshotNeo documentation for request parameters and account setup. The example below demonstrates a public page; replace the URL with a page you are authorized to capture and add the appropriate supported authentication settings when needed.

cURL

curl -G "https://api.screenshotneo.com/v1/shot" \
  -d access_key=YOUR_API_KEY \
  --data-urlencode url=https://stripe.com \
  -o shot.webp

Python

import requests

r = requests.get(
    "https://api.screenshotneo.com/v1/shot",
    params={"access_key": "YOUR_API_KEY", "url": "https://stripe.com"},
    timeout=90,
)
r.raise_for_status()
with open("shot.webp", "wb") as f:
    f.write(r.content)

Node.js

const q = new URLSearchParams({
  access_key: 'YOUR_API_KEY',
  url: 'https://stripe.com'
});
const res = await fetch(`https://api.screenshotneo.com/v1/shot?${q}`);
if (!res.ok) throw new Error(`Screenshot request failed: ${res.status}`);
const bytes = new Uint8Array(await res.arrayBuffer());
await Bun.write('shot.webp', bytes);

The Node.js example uses Bun’s file writer. In Node.js, save bytes with writeFile from node:fs/promises instead:

import { writeFile } from 'node:fs/promises';

const q = new URLSearchParams({
  access_key: 'YOUR_API_KEY',
  url: 'https://stripe.com'
});
const res = await fetch(`https://api.screenshotneo.com/v1/shot?${q}`);
if (!res.ok) throw new Error(`Screenshot request failed: ${res.status}`);
await writeFile('shot.webp', new Uint8Array(await res.arrayBuffer()));

Options relevant to an authenticated capture

Need Approach Things to check
Pass an authenticated state Use supported cookies, custom headers, or Authorization. Use only credentials you are authorized to use. Session cookies are sensitive; keep keys and cookie values out of source control, logs, and public links.
Wait for the page to settle Wait for a selector, a delay, or network idle. A fixed delay can be too short or waste time. A selector is useful when a known page element indicates readiness.
Capture a specific area Use full-page capture or capture one element by CSS selector. Check that the target exists after login and that overlays do not obscure it.
Handle consent and overlays ScreenshotNeo can accept the cookie/consent banner like a visitor and remove 60+ known consent platforms, newsletter popups, and chat widgets before capture. Each step can be turned off. Consent behavior is site-specific. Confirm the resulting state is appropriate for your purpose.
Control appearance Set viewport or device preset, dark mode, and retina scale; apply custom CSS or JavaScript if needed. Custom page changes can affect what the image represents. Keep a record of any modifications if the screenshot is evidence.
Reduce unwanted requests Block ads, trackers, selected requests, or resource types. Blocking a resource the page depends on can leave it incomplete.

Other available ScreenshotNeo options include hiding selectors, clicking an element before capture, custom user agent, timezone and geolocation, transparent background, image resizing, caching with a chosen TTL, signed links for public image tags, async jobs with signed webhooks, bulk capture of up to 100 URLs per call, a usage API, and an OpenAPI spec. PDF options include paper size, margins, landscape, and page ranges. HTML or CSS can also be rendered to an image. Parameter names used by other screenshot APIs also work, which can make switching easier. See the API documentation for the exact parameters.

5. Troubleshooting

Symptom Likely explanation What to do
The page appears logged out after clearing data. Cookies or other site data may have held session state. Return to the existing authenticated tab or sign in again through the site. Avoid clearing storage as a banner workaround.
The consent banner returns after reload. The site’s consent persistence and browser state determine whether the choice is remembered; the banner alone does not prove the login failed. Use the site’s own consent controls, wait for the page to settle, and capture the intended state. Inspect storage if diagnosing, without deleting it.
The screenshot shows a loading frame or incomplete page. The capture happened before the page or delayed content settled, or it came from Chrome’s Network screenshot feature. Wait for completion and take a regular screenshot. For automation, wait for a relevant selector, delay, or network idle.
The full-page image is missing content or includes overlays. Some content loads on scroll, and sticky or floating elements can affect full-page output. Try a settled full-page capture, inspect the result, or capture the relevant element or viewport instead.
An API capture is not authenticated. The API request does not inherit the browser’s logged-in session. Supply authorized cookies or headers through supported parameters, and verify the session is valid for the requested host.
An automated capture is blank or times out. The page may be blocked, unavailable, slow, or waiting on a condition that never occurs. Check the target URL and readiness condition. ScreenshotNeo responses identify page verdict and billing status in X-Page-Verdict and X-Billed headers.

6. Performance, reliability, and cost

For a manual capture, waiting for the settled state is usually more useful than taking repeated screenshots during a reload. Full-page images include more content and may take longer to render than a viewport capture. In automated workflows, use a readiness condition that reflects the page you need; network idle may never arrive on pages with ongoing requests, while a fixed delay cannot guarantee that a specific element has loaded.

Keep the authenticated browser session intact for reliability. For API workflows, treat credentials as secrets and consider whether a session can expire or be restricted to a browser. ScreenshotNeo says only clean shots are billed: bot checks or CAPTCHAs, blank pages, timeouts, failed loads, and cache hits cost nothing. Each response reports the page verdict and billing status in X-Page-Verdict and X-Billed.

ScreenshotNeo pricing is $0 for 1,000 shots per month with no card, $5 for 3,000 on Starter, $15 for 15,000 on Growth, $39 for 60,000 on Pro, $99 for 250,000 on Scale, and $249 for 1,000,000 on Business. Yearly billing gives two months free, and every feature is available on every plan. A one-off browser screenshot does not require a paid service.

7. Or skip the browser setup

For an automated URL capture, make one GET request to ScreenshotNeo. This sample captures a public page; for a logged-in page, add authorized cookies or headers as described in the docs.

curl -G "https://api.screenshotneo.com/v1/shot" -d access_key=YOUR_API_KEY --data-urlencode url=https://stripe.com -o shot.webp

ScreenshotNeo removes cookie banners, popups, and chat widgets before the shot; bot checks, blank pages, and failed loads are never billed; an MCP server lets AI agents take screenshots; and 1,000 screenshots a month are free with no card, with paid plans starting at $5 for 3,000.

Sign up for 1,000 free screenshots a month with no card.

8. Frequently asked questions

Does a banner reappearing mean my login expired?

No conclusion follows from the banner alone. Login state and consent persistence are site-specific and may use different browser storage.

Should I delete cookies to make a clean screenshot?

No. Cookies can carry session state. Use the site’s consent controls and preserve the current data if you want to keep the session.

When should I use Chrome Network screenshots?

Use them to diagnose what appears during loading. For the final settled view, take a regular viewport or full-page screenshot.

Will a screenshot API automatically use my browser login?

No. An API request is separate from the browser session; provide authorized authentication state through supported request settings.