Consent Management Platform · built for developers & agencies

The cookie banner that makes your site faster.

Most CMPs are a tax — they block rendering, shift your layout and gut your Core Web Vitals. Lightning does the opposite: 100/100 Lighthouse with the banner running, WCAG 2.1 AAA, and one license that covers every client site.

100/100
Lighthouse, banner live
0
Cumulative layout shift
~12KB
Gzipped, zero deps
~1ms
Edge license check
The problem

Cookie banners are a tax.

You did the right thing and added a consent banner. Then your Lighthouse score fell off a cliff, your devs couldn't tell why a tag wasn't firing, and your marketing team watched conversions "disappear." Lightning was built to fix all three.

It tanks your speed

Render-blocking scripts, layout shift when the banner pops, megabytes of vendor JS and web fonts. Core Web Vitals go red — and so does your SEO.

Fixed: ~12 KB, async, Shadow-DOM, contain:layout, zero CLS. The page still scores 100.

You can't see why a tag is blocked

"Why isn't GA firing?" Most CMPs are a black box. Debugging blocked scripts means guesswork and trawling the network tab.

Fixed: LightningCMP.debug() prints consent state, live Consent Mode signals and every gated script with its reason.

You lose attribution & analytics

Do consent properly and a chunk of users opt out — so your numbers drop versus the cowboys who just don't bother. That hurts.

Fixed: correct Consent Mode v2 lets Google model the denied conversions back. We even warn you when a tag is hard-blocked.
Quick start

Two script tags. Done.

Framework-agnostic. Drop it in the <head> or ship it through Google Tag Manager. Already on Cookiebot? Keep your data-cookieconsent markup — migration is a copy-paste.

<!-- 1. Consent Mode defaults + async queue (in <head>) -->
<script>
  window.dataLayer = window.dataLayer || [];
  function gtag(){ dataLayer.push(arguments); }
  gtag('consent','default',{ad_storage:'denied',analytics_storage:'denied',
    ad_user_data:'denied',ad_personalization:'denied',wait_for_update:500});
  !function(c){c.lightning=c.lightning||function(){(c.lightning.q=c.lightning.q||[]).push(arguments)}}(window);
</script>

<!-- 2. The SDK, gated to your licensed domain at the edge -->
<script async src="https://cmp.lightning-consent.io/v1/cmp.js?k=YOUR_KEY"></script>
<script>lightning('init', { theme: 'light' });</script>

Your visitor's region (GDPR / CCPA / none) is resolved at the edge and baked into the script — the right banner shows with zero extra round-trips.

The headline

A perfect score, with the banner on.

Measured on the live deployed demo — Lighthouse, mobile, 4× CPU throttle, slow 4G. The banner renders and the page still scores 100.

MetricResult
Performance score100 / 100
Largest Contentful Paint0.8 s
Cumulative Layout Shift0
Total Blocking Time0 ms
First Contentful Paint0.8 s
  • Async-loaded — never blocks the parser or paint; a tiny queue replays early calls in order.
  • Zero layout shift — Shadow DOM, position:fixed, contain:layout style. It never pushes your content.
  • No web fonts — system stack, nothing extra to download.
  • Lazy — the cookie list loads only when the preferences modal opens.
  • Edge-served from Cloudflare with a preconnect hint and ~1 ms license checks.
For developers

A CMP you can actually debug.

Built by engineers who got sick of consent black boxes. Observable, typed end-to-end, fail-soft, and honest about what it's blocking.

// "Why is this cookie blocked?"
> LightningCMP.debug()

consent:  { necessary:true, statistics:false, marketing:false }
signals:  { analytics_storage:'denied', ad_storage:'denied' }
scripts:
  _ga          blocked   needs: statistics
  gtag/js      blocked   needs: marketing
  hotjar       activated granted: statistics
⚠ hint: google tag hard-blocked — prefer Consent Mode
            modelling over removing the tag.
  • Drop-in & framework-agnostic — one script (or GTM) + init().
  • Cookiebot-compatible markup — migrate with no markup changes.
  • Debug mode three waysdebug:true, ?lightning-debug, or a localStorage flag. No redeploy on a live site.
  • Fail-soft everywhere — a backend outage never breaks consent; a bad license is a no-op that logs the reason.
  • TypeScript end-to-end — clean API: init, getConsent, onConsentChange, openPreferences, acceptAll, rejectAll, reset, debug.
  • Tested & documented — 115 tests, full pnpm reference, per-package READMEs.
How we compare

Lightning vs the incumbents.

The big CMPs charge per domain and bolt the banner on top of your page. We built ours into the edge.

 LightningCookiebotUsercentrics
Script size, gzipped~12 KB
whole SDK
~37 KB
loader only
~16 KB+
loader only
100/100 Lighthouse with bannerYesNoNo
Zero layout shift (CLS 0)YesRarelyRarely
First-party — no third-party CDNYesLoads from cookiebot.comLoads from usercentrics.eu
Self-hosted on your own accountYesNoNo
WCAG 2.1 AAA bannerYesAA-ishAA-ish
Built-in "why is this blocked?" debugYesNoNo
Attribution-recovery hintsYesNoNo
AI cookie auto-categorisationYesManualPartial
Pricing modelFlat, multi-sitePer domainPer domain
Agency / white-label dashboardYesLimitedAdd-on
Google Consent Mode v2YesYesYes

Sizes measured live from each vendor's loader (gzip, Jun 2026). Competitor "loader only" figures understate the real download — both fetch additional UI, config and translation bundles at runtime; our ~12 KB is the entire SDK. Comparison reflects typical out-of-the-box behaviour; competitor results vary by configuration.

The full list

Everything in the box.

No "enterprise tier" asterisks. Every Lightning license ships the whole platform — compliance, performance, accessibility, AI, analytics and the agency tooling.

⚖️ Compliance & regulation

  • Google Consent Mode v2 — 4 categories mapped to all 7 signals
  • GDPR opt-in model — no pre-ticked non-necessary boxes
  • CCPA / CPRA opt-out + "Do Not Sell or Share"
  • Global Privacy Control (GPC) — automatic opt-out
  • Geo-adaptive — GDPR / CCPA / none resolved at the edge
  • 4 categories: Necessary, Preferences, Statistics, Marketing
  • Equal-prominence Accept / Reject
  • Withdraw consent as easily as giving it (floating button)
  • Versioned, first-party consent string

Performance

  • 100/100 Lighthouse with the banner running
  • ~12 KB gzipped — vs Cookiebot's ~37 KB loader. ~3× lighter
  • Zero runtime dependencies
  • Zero CLS — Shadow DOM, contain:layout style
  • Zero render-blocking — fully async
  • First-party — no third-party CDN; CMP sets no cookies of its own
  • Function-stub queue replays early calls in order
  • No web fonts (system stack)
  • Lazy cookie list — loads only on modal open
  • Edge-served from Cloudflare + preconnect
  • Regulation baked into the script — zero extra round-trips

🛠️ Developer experience

  • Drop-in — one script (or GTM) + init()
  • Cookiebot-compatible data-cookieconsent markup
  • Script auto-blocking (type="text/plain")
  • debug() — consent, live signals, gated-script table
  • Debug mode 3 ways — flag / ?lightning-debug / localStorage
  • Attribution-recovery hints on hard-blocked tags
  • Fail-soft — outage or bad license never breaks the page
  • TypeScript end-to-end, clean public API
  • 115 tests · per-package READMEs · full pnpm reference

Accessibility — WCAG 2.1 AAA

  • 7:1 contrast — test-enforced in CI
  • 44 px minimum target size
  • Full keyboard navigation + focus trap
  • ARIA roles + aria-live announcements
  • Visible focus states throughout
  • Screen-reader tested

🤖 AI & cookie inventory

  • AI auto-categorisation (Claude Haiku 4.5)
  • Plain-language, multi-language descriptions
  • Known-cookie list with AI fallback
  • Cached by name+domain — categorise once across all sites
  • Fail-safe: unknown cookies default to most restrictive
  • Always-accurate inventory from your site scan
  • Batch API for bulk scans (50% cheaper)

📊 Analytics & optimisation

  • Consent funnel analytics + opt-in rate
  • A/B banner testing — deterministic variant assignment
  • Per-site breakdowns in the dashboard
  • Accept / reject / partial decision tracking

🧾 Audit & receipts

  • Consent receipts — Kantara-style, hash-anchored
  • Append-only, auditable consent log (D1)
  • Exportable proof-of-consent for legal/enterprise
  • Per-record receipt hash returned on capture

🔒 Security & licensing

  • Domain-locked — runs only on authorised domains
  • License + domain validated at the edge on serve
  • Backend enforcement via unspoofable Origin
  • HMAC-SHA256 signed license tokens
  • Subscription-status aware
  • Copied script on an unlicensed domain refuses to render

🏢 Agency & platform

  • One license → many client sites
  • Near-zero marginal cost per site (self-hosted on Cloudflare)
  • Central admin dashboard — analytics, cookies, config
  • White-label — theme tokens + per-site branding
  • Light / dark / auto + fully custom themes
  • Per-site config overrides, merged over inline init()
  • Manual category overrides win over AI
For agencies

One license. Every client site.

Per-domain CMP pricing punishes agencies for having lots of clients. Lightning is self-hosted on Cloudflare, so each new sub-site costs you almost nothing — and you manage them all from one place.

Near-zero per-site cost

Edge-served from Cloudflare Workers. Add a client site without adding a license bill.

Central dashboard

Analytics, cookie review/override and per-site config across every site you run — one login.

White-label ready

Theme tokens and per-site config let the banner wear your client's brand, not ours.

AI does the cookie chore

Claude auto-categorises the cookies your scanner finds — no more manual labelling per site.

Domain-locked & protected

The script only runs on paying, authorised domains — validated at the edge and enforced server-side via the unspoofable Origin header.

Auditable consent

Kantara-style consent receipts + an append-only log = real proof-of-consent for your enterprise clients.

Who built it

Made by an agency, for agencies.

Lightning CMP comes out of Contra — a London web design & development agency, 26 years in, running a lot of client sub-sites. We were paying per-domain for Cookiebot and the maths stopped working. So we built the consent platform we actually wanted: fast, observable, accessible, and priced for portfolios.

"Creative thinking. Technical mastery." — same crew, now applied to consent. We're on your side, we keep it simple, we get it done.

Royal SocietyAlan Turing InstituteNational Film & TV SchoolSquare EnixGreat Ormond Street

Built on Cloudflare

  • Workers + D1 + KV at the edge
  • Self-hosted — your data, your account
  • HMAC-signed license tokens
  • Open, documented, TypeScript

Stop paying per domain.

Get a license, drop in two script tags, and ship a faster, more accessible, fully compliant banner across every site you run.