Jakub Ruciński
JAKUB RUCIŃSKIWEBSITE TOOLS & ANALYTICS
PL
HomeProjectsCustom-Built CMP & Google Consent Mode v2
Cloudflare Edge Architecture • Headless CMP • Google Consent Mode v2

Custom-Built CMP & Google Consent Mode v2

I engineered a custom-built consent management and privacy engine (Headless CMP) executing directly at the Cloudflare Edge. It completely eliminates monthly subscription fees, imposes zero limits on pages or pageviews, and deploys effortlessly to any web property or e-commerce store with a single line of code in Google Tag Manager.

Why This Architecture Wins

Core Business & Technical Advantages

Cost Savings
$0/mo Subscription Fees

Eliminate Perpetual Monthly Tool Costs

Off-the-shelf CMP tools charge heavy recurring monthly fees per domain that inflate rapidly as your traffic and page count grow. With this proprietary solution, there are no ongoing software taxes – you pay once for a tailored, professional implementation, and the engine serves your business indefinitely.

Scalability
Unlimited Pages & Traffic

Zero Artificial Caps with Infrastructure Freedom

No artificial paywalls for reaching 100 or 500 subpages. For high-traffic enterprises or businesses requiring absolute infrastructure sovereignty, the engine can be deployed directly on the client’s own free Cloudflare account (for a one-time setup fee). The database, telemetry, and code remain 100% within your corporate control.

Analytics
Advanced Consent Mode Ready

Flawless Pipeline for Google AI Conversion Modeling

Many off-the-shelf plugins default to "Basic" consent mode, entirely cutting tags and blinding analytics. Our architecture strictly delivers Google Consent Mode v2 Advanced, piping clean, cookieless pings directly to Google without race conditions. Once traffic meets Google’s algorithmic training thresholds (1,000+ daily events), GA4 and Google Ads model conversions seamlessly to keep Smart Bidding accurate.

UX Trust
100% GDPR in Plain Language

User-Centric Clarity Over Intimidating Legal Walls

Fully compliant with European data protection regulations (GDPR / ePrivacy), but written for real humans. Clear, concise explanations replace intimidating legal jargon, fostering user trust and directly boosting voluntary opt-in rates.

Implementation
1 Line of Code in GTM

Frictionless Setup Without Core Code Changes

No weeks spent waiting on developer backlog availability or touching core codebase templates. The implementation runs seamlessly through a single asynchronous script tag inside Google Tag Manager.

Compliance
Cryptographic Consent ID

Irrefutable Audit Trail with Instant Legal Defense

Every decision generates an immutable cryptographic Consent ID logged in Cloudflare D1 with an exact UTC timestamp, page URL, and granular category breakdown. In the event of a regulatory inquiry, you have comprehensive proof of compliance.

Interactive Playgrounds

Test The Mechanisms Live (Live Simulator)

Experience the core mechanics below: switch between 2-button and 3-button UX layouts, test Cloudflare Edge geo-targeting, observe live Google Consent Mode v2 dataLayer pushes, and inspect the cryptographic audit trail.

Interactive Showcase #1

Live Banner Simulator: 2 Buttons vs 3 Buttons

Test how the user experience changes depending on your business and legal strategy.

🍪

We respect your privacy

✓ Compliant with Google Consent Mode v2 & GDPR

We use cookies and related technologies to ensure smooth site performance, analyze traffic, and tailor advertising. No stiff legal jargon – you stay in complete control of your data. Privacy Policy →

Interactive Showcase #2

Smart Geo-Targeting (GDPR vs Global Traffic)

Automatically detect visitor country at the Cloudflare Edge (0ms overhead). Apply strict opt-in only where required by law.

Default Consent State:DENIED (Until user gives consent)
Banner presentation:Enforced consent modal banner
Analytics data capture:Consent Mode v2 Modeling (100% GDPR)
Interactive Showcase #3

Live DataLayer & Consent Mode v2 Inspector

Inspect how window.dataLayer and gtag() respond when interacting with the banner above.

// 1. Google Consent Mode v2 API Call:
gtag('consent', 'update', {
  ad_storage: 'denied',
  analytics_storage: 'denied',
  ad_user_data: 'denied',
  ad_personalization: 'denied'
});
// 2. DataLayer Event for GTM Triggers:
dataLayer.push({
  event: 'cookie_consent_ready',
  action: 'INITIAL_LOAD',
  consent_id: 'c_init_7x9w2k'
});
Interactive Showcase #4

Revisit Consent Badge (GDPR Right to Change Mind)

GDPR legally requires users to easily modify their consent anytime. Choose the icon and screen corner.

Widget Icon:
Screen Position:
Preview: Website corner with floating badge
🍪
Interactive Showcase #5

Cryptographic Audit Trail (Legal Proof)

Each decision generates a unique Consent ID logged into Cloudflare D1 with UTC timestamp and exact URL.

c_9x2k4m1w7qhttps://twojadomena.pl/
ACCEPT_ALL15:42:10
c_8k3p9z0a1bhttps://twojadomena.pl/cennik
SAVE_CUSTOM15:39:55
c_7f4q2d8r9thttps://twojadomena.pl/blog/artykul-1
ACCEPT_NECESSARY15:31:02
c_3m9x1v4k7bhttps://twojadomena.pl/kontakt
ACCEPT_ALL15:18:40
Architectural Comparison

Traditional SaaS CMPs vs Custom Cloudflare CMP

Feature / DimensionGeneric SaaS ToolsCustom CMP (Cloudflare Edge)
Billing ModelPerpetual monthly fee (scales with traffic)One-time implementation ($0/month)
Page / Product CapsStrict thresholds (100 or 500 subpages)Unlimited pages, products & views
Core Web Vitals ImpactHeavy libraries (200–400 KB), LCP/INP lagUltra-light edge script, CLS = 0
CSS EncapsulationFrequent layout clashes with store styles100% encapsulated in Shadow DOM
Self-Hosted OptionNone (vendor lock-in)Deployable on client's own Cloudflare account
Google Consent Mode v2Frequent race conditions & GTM misfiresNative dataLayer & gtag() orchestration
Deployment & Consultation

Deploy Custom CMP on Your Website

Ready to recover advertising insights, cut recurring software overhead, and ensure bulletproof compliance? Get in touch to schedule your implementation.

Direct Consultation

Your information is confidential and will strictly be used to respond to this consultation inquiry.

Transparent Workflow

Wondering how the collaboration looks step by step?

No multi-week briefs, Figma mockups, or crystal-ball forecasting. Explore my 5 straightforward phases: from first discovery & PRD, through a live clickable version with inline feedback, to robust CRO tracking and launch.

Live working version from day oneContinuous email updates & decision alertsNo forced subscriptions or retainers
Interactive roadmap & deliverables
Explore Collaboration Model