close
close
This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.

Consent Banner Speed Test

Measure how quickly a website's consent banner loads and appears, on matched desktop and mobile test runs.

Privacy & Compliance Intermediate Consent banner speed DataGrail team Works with Codex desktop (needs Node.js and Playwright) Updated November 2026
When to use

When to reach for it

Use it when you want to see what a visitor sees from a consent banner.

  • Checking how fast a site's consent banner appears on desktop and on mobile.
  • Finding out which consent tool a site probably uses.
  • Running a quick, neutral diagnostic on one or more public sites.
  • Preparing evidence for a comparison, which only becomes a claim after the quality gate passes.
Controlled test

How it compares in a controlled test

In one controlled test, DataGrail's standard banner reached the visitor with a shorter chain of requests, a smaller download and no render-blocking request.

Measure DataGrail Alternative
Requests 1 15
Download size 46.8 KB 711 KB
Chain depth to banner 1 4
Render-blocking requests 0 1
Banner visible (mobile) 1.8 s 7.1 s
Banner visible (desktop) 1.4 s 4.0 s
First contentful paint (mobile) 200 ms 1.6 s

Measured 2026-10-24 in a controlled test on replica pages, EU visitor, simulated slow mobile profile, medians of interleaved cold loads. Live sites and your own results will differ.

The desktop banner time was measured on the test machine's own network, not the simulated mobile profile.

What it does

What it measures

Give it a public website URL. It loads the site in a fresh local browser, several times, on a desktop profile and a mobile profile, and records how the consent banner behaves.

  • When the banner appears. The time until a visitor can see the banner, with the range across runs.
  • Which consent tool is likely in use. It identifies the probable consent platform and the consent footprint it leaves on the page.
  • Honest gaps. If no banner shows up, the result says Not detected. If a run is blocked, it says Not measured. Neither is ever reported as zero.
  • A report you can hand on. You get a branded summary image, a detailed HTML report, a full-page image of that report, and the raw JSON.

A comparison against a DataGrail implementation needs an approved benchmark, and the skill applies a quality gate before it will produce a claim that one banner is faster than another.

The skill

Get the skill

One folder holds SKILL.md, a methodology reference and the local Playwright script that runs the test. Download the .zip and follow the install steps below.

What’s in the folder
consent-banner-speed-test/
  SKILL.md                          # Skill entry point the agent reads first
  package.json                      # Playwright dependency for the runner
  pnpm-lock.yaml                    # Lockfile
  agents/
    openai.yaml                     # Codex display name and default prompt
  references/
    methodology.md                  # Quality gate and how to read a comparison
  scripts/
    audit.cjs                       # The local Playwright runner
  assets/
    DataGrail logos (SVG)           # Used in the share image
SKILL.md core file
Download .zip
---
name: consent-banner-speed-test
description: Audit a live website’s consent banner against an approved DataGrail implementation on matched desktop and mobile runs, identify the likely CMP and consent footprint, apply publication-quality gates, and generate detailed HTML/JSON plus a branded PNG summary. Use for consent-banner speed tests, CMP comparisons, cookie-banner diagnostics, and DataGrail competitive evidence. Do not use for legal compliance conclusions or claims that have not passed the included quality gate.
---

# Consent Banner Speed Test

Measure what a visitor actually experiences. Preserve every result internally, but generate an external comparison claim only when the evidence passes the quality gate.

## Comparison input

Accept one public target URL. Compare it with one DataGrail implementation that the user or DataGrail team has approved as the benchmark.

Use the environment variable `DG_CONSENT_BASELINE` in `Label|URL` form when the environment has an approved default. Otherwise ask for the approved benchmark URL before running a competitive comparison. Do not silently use a vendor marketing site or pick a customer merely because its logo appears on a customer page.

Default comparison conditions:

- five fresh-browser runs per URL and device
- desktop and mobile profiles
- a 15-second banner-detection window
- the user's current locale and timezone when known
- one region disclosed in the report
- balanced sequential order so the same URL is not always tested first

## Run the comparison

Use [scripts/audit.cjs](scripts/audit.cjs). It needs Node.js, Playwright, and a Chromium-compatible browser. First use the skill's local `node_modules/playwright` when present. Otherwise, in Codex desktop call `load_workspace_dependencies` and use the bundled Node.js packages. Then run:

```bash
NODE_PATH="<node_modules>" "<node>" scripts/audit.cjs 
  --target "Target site|https://example.com" 
  --baseline "Approved DataGrail benchmark|https://approved.example" 
  --baseline-approved 
  --region-label "California, US" 
  --output-dir "<absolute-output-directory>"
```

Run the audit from the local command environment. Do not use the in-app browser, computer-use browser, `web.open`, or a personal browser as the measurement surface. Those surfaces may return `ERR_BLOCKED_BY_ADMINISTRATOR` even when the website is reachable and the Playwright runner works.

If the local runner reports a navigation or security-page block, preserve that first result and perform one diagnostic check with an ordinary HTTP HEAD request. A successful HEAD request does not count as a measurement; it only distinguishes a browser-surface restriction from a site or network block. When full local Chrome is available, rerun the entire matched session once with `--headed` and an explicit `--chrome-path`, keeping every other condition unchanged. Use the complete replacement session only if no tested profile returns a block page. If the headed retry is also blocked, keep the result as blocked and do not substitute inferred data.

`--baseline-approved` means the benchmark is approved for external comparison use. It does not mean the resulting claim is approved. The script still applies the evidence gate.

Use `--help` for all options. Without a baseline, repeatable `--target` values still run a neutral multi-site diagnostic with three runs per device.

## Outputs

Keep the generated files together:

- `consent-speed-share.png`: concise DataGrail-branded result image, including a clear blocked or inconclusive state
- `consent-speed-report.html`: detailed diagnostic report
- `consent-speed-report.png`: full-page rendering of the detailed report
- `consent-speed-audit.json`: raw measurements, comparisons, and quality-gate status
- first-run screenshots for every URL/device pair

The share image must still be produced when access is blocked or no banner is detected. Missing measurements are labeled `Not detected` or `Not measured`, never `0 ms`.

## Publication quality gate

Read [references/methodology.md](references/methodology.md) before interpreting a comparison or writing competitive copy.

A device-profile claim is `publishable` only when all of these are true:

- both sites have at least 80% detection coverage, with a minimum of two successful detections
- the benchmark has direct DataGrail evidence
- the benchmark was explicitly marked approved
- the DataGrail median is faster than the target median
- the observed ranges do not overlap

The overall report is externally publishable only when every tested profile passes. Otherwise it is `internal_review`. Do not hide, rewrite, or reverse an unfavorable result. Keep it internal and either diagnose the implementation or run a new matched session for a legitimate methodological reason.

Use “faster in this test” rather than an unqualified product-wide claim. A live-site test measures the whole implementation: CMP configuration, tag manager, network, page code, geography, and vendor delivery.

## Failure handling

If bot protection, authentication, a CAPTCHA, an administrator policy, or a network restriction blocks a site:

- preserve the error in JSON
- generate the blocked-state share image
- report the target as unmeasured
- do not substitute a search result, earlier benchmark, or inferred CMP

## DataGrail content handoff

When the user also requests Daniel Barber or DataGrail LinkedIn copy, hand only current-session, quality-gated results to `dg-content-machine`. Get human approval before publishing, sharing outside the intended audience, or scheduling the post.
Install it
01

Install Node.js

Install a current Node.js LTS release from nodejs.org. Then open Terminal on macOS or PowerShell on Windows and confirm it works with node --version and npm --version.

02

Unzip the skill

This skill runs in the Codex desktop app, not in an ordinary Chrome or Safari tab. Extract the .zip into the Codex skills directory, for example mkdir -p "$HOME/.codex/skills" and then unzip the download into it, and open the new consent-banner-speed-test folder.

03

Install Playwright and Chromium

From inside the consent-banner-speed-test folder, run npm install and then npx playwright install chromium. Restart Codex when it finishes.

Run it
01

Start with a one-site diagnostic

Ask: "Use the consent-banner-speed-test skill to run a one-site diagnostic on https://example.com from California. Run the included local Playwright script and generate the complete output package." This needs no DataGrail benchmark.

02

Compare against a benchmark

Once a benchmark is approved and set up (or you give Codex its URL), ask: "Compare the consent-banner speed on https://example.com with our approved DataGrail benchmark." A comparison uses five fresh-browser desktop runs, five mobile runs and a 15-second detection window.

03

Review the output

You get a share image, a detailed HTML report, a full-page report image and the raw JSON. Missing data is labelled Not measured or Not detected, never zero.

Example

You ask

Use the consent-banner-speed-test skill to run a one-site diagnostic on https://www.your-site.example from California. Run the included local Playwright script and generate the complete output package.

You get back

Illustrative example. The figures are made up to show the layout.

Diagnostic complete
Your Site audit results. Region: California, US. 3 runs per device.
No DataGrail benchmark was supplied, so no competitive claim was generated.

desktop, 3/3 detected
  Median time to visible banner: 1.85s
  Observed range: 1.62s-2.10s
  Likely CMP: Not identified
  Consent requests: 6
  Observed transfer: 42 KB
  Median FCP: 0.31s   Median LCP: 0.45s

mobile, 2/3 detected
  Median time to visible banner: 2.94s
  Observed range: 2.71s-3.30s
  (the run with no banner shows Not detected, never 0)

Files: consent-speed-share.png, consent-speed-report.html,
consent-speed-report.png, consent-speed-audit.json,
plus a first-run screenshot for each device
Limits

Limits

This skill is a diagnostic. Read a result with these limits in mind.

  • It needs a terminal and Node. It runs a local Playwright script, so it does not run inside an ordinary browser tab.
  • Region matters. The region you give is a label for the report. The test runs from your own machine and network, so run it from the place you want to report on. Banners are shown according to where the visitor appears to be, and US visitors often get no banner at all, so Not detected does not mean zero milliseconds and does not mean non-compliant.
  • Results depend on the test machine and the network. Compare runs made under the same conditions, not against a number from somewhere else.
  • Bot walls can block a run. If a site shows a security page, the run is reported as blocked and nothing is guessed.
  • A live site is measured as a whole. The result covers the consent tool, the tag manager, the page code and the network together, not the vendor in isolation.
  • It is not a compliance or legal assessment. It is a performance observation, not legal advice or a compliance certification.
  • The DataGrail comparison appears once Product approves a benchmark. Until then the skill runs a neutral diagnostic on the sites you give it.
Consent Management

Measure the banner.Then fix it.

DataGrail Consent Management is built to load fast and to keep every consent choice in one place, so the banner your visitors see is also the one you can prove.