Research

How to Implement CookieYes with Webflow Analyze: A Complete Setup Guide

Learn how to install CookieYes on a Webflow site and connect it to Webflow Analyze using a consent-aware event listener. Complete setup guide with code, testing steps, and FAQs.
AUTHOR
Greater
Date Published
March 20, 2026
LAst Updated
March 20, 2026
TAg
Article

Overview

Webflow Analyze gives marketing teams a privacy-first way to track website behavior without relying on cookies. But for sites that also run cookie-dependent tools like Google Analytics or Meta Pixel, pairing Analyze with a proper consent management platform is still necessary.

This guide walks through how to connect CookieYes to a Webflow site and wire it up to Webflow Analyze so that tracking genuinely respects user consent in real time — not just visually, but technically.

Key Takeaways

  • Privacy-First Integration: Webflow Analyze is cookieless by default, but requires the User Tracking API for enhanced behavioral data.
  • Consent Gating: Use wf.allowUserTracking() and wf.denyUserTracking() to sync CookieYes signals with Webflow's native analytics.
  • Real-Time Updates: The implementation uses event listeners (cookieyes_consent_update) to ensure tracking changes immediately when a user updates their preferences.
  • Compliance: This setup helps meet GDPR and CCPA requirements by ensuring tracking scripts only fire after explicit user consent.

What this guide covers

This guide is written for Webflow developers, marketing technologists, and web managers who need a compliant consent management setup on a Webflow site running Webflow Analyze. It covers both the CookieYes installation and the custom event listener integration that connects consent signals to Webflow Analyze's user tracking API.

That second part — the event listener code — is what CookieYes's own Webflow documentation doesn't currently address. That's the gap this guide fills.

Who this guide is for

This is most useful if you're running Webflow Analyze alongside cookie-based tools like Google Analytics, Meta Pixel, or Hotjar, and need those tools to respect user consent in a way that's technically enforceable. Not just a banner that looks right, but one that actually blocks scripts until consent is given.

It assumes basic familiarity with Webflow's custom code settings and browser developer tools for testing.

Topics covered

  • What CookieYes is and how it works
  • What Webflow Analyze is and when it requires consent
  • Why consent management is a legal and technical requirement, not just a UX consideration
  • Step-by-step CookieYes installation on a Webflow site
  • How to wire CookieYes consent events to Webflow Analyze using a custom event listener
  • How the integration code works and what each part does
  • Frequently asked questions about the setup
  • Resources and support options

What this guide does not cover

This guide focuses specifically on the CookieYes and Webflow Analyze integration. It doesn't cover Google Tag Manager setup, Google Consent Mode v2 configuration, or legal advice on whether your site requires a consent banner under applicable regulations. For jurisdiction-specific compliance questions, talk to a legal professional.

What is CookieYes?

CookieYes is a consent management platform (CMP) that handles cookie consent banners, preference centers, and compliance documentation for websites operating under privacy regulations including GDPR, CCPA, and CPRA. It scans your site for cookies, categorizes them automatically, and serves a configurable banner that lets users accept, reject, or customize their consent choices.

Beyond the banner, CookieYes generates and maintains a cookie policy, logs consent records for audit purposes, and integrates with Google Consent Mode v2. It works across platforms including Webflow, WordPress, Wix, and Squarespace, and is used by over 1.5 million websites.

For Webflow sites specifically, CookieYes installs via a script tag added to the site's custom code settings. No plugins or third-party app installations required.

What is Webflow?

Webflow is a visual web development platform that lets designers and marketing teams build production-ready websites without writing code by hand. It generates clean, semantic HTML, CSS, and JavaScript from a visual canvas, and includes a built-in CMS, hosting, form handling, and a growing suite of analytics and optimization tools.

Because Webflow outputs real front-end code rather than template markup, teams get significantly more control over performance, SEO, and integrations compared to template-based platforms. Custom code can be injected at the site level or on individual pages, which is what makes adding third-party tools like CookieYes straightforward.

What is Webflow Analyze?

Webflow Analyze is Webflow's native, privacy-first analytics product. It tracks pageviews, sessions, traffic sources, and user behavior without using cookies — which means it doesn't require consent under most privacy frameworks right out of the box.

That said, Webflow Analyze includes a user tracking API that lets you opt users into more detailed behavioral tracking when they give consent. This is where CookieYes integration becomes relevant. When a user consents to analytics cookies via the CookieYes banner, you can use that signal to call wf.allowUserTracking() and enable the enhanced tracking layer. When they decline or withdraw consent, you call wf.denyUserTracking() to switch it off.

The result is an analytics setup that's both compliant and accurate. Cookieless data is always collected. Richer session data gets layered on only when the user has explicitly opted in.

Why consent management actually matters

Privacy regulations have shifted from best practice to legal requirement for most websites with visitors in the EU, UK, California, and a growing number of other jurisdictions. The key compliance drivers:

  • GDPR (EU/UK): Requires a lawful basis — usually informed consent — for processing personal data via analytics and marketing cookies.
  • CCPA/CPRA (California): Grants users the right to opt out of the sale or sharing of personal data, including behavioral tracking.
  • Financial Risk: Non-compliance can result in fines up to 4% of global annual revenue.
  • User Trust: Transparent consent flows signal that a business takes data privacy seriously.

Here's the thing a lot of teams miss: displaying a consent banner without technically blocking tracking scripts until consent is given isn't sufficient under GDPR. A banner that fires Google Analytics or Meta Pixel on page load regardless of what the user selects is still non-compliant, even if it looks right to the visitor. The consent mechanism needs to be functional, not decorative.

How to implement CookieYes in Webflow and activate Webflow Analyze

This implementation has two parts: installing the CookieYes banner on your Webflow site, then connecting CookieYes consent events to Webflow Analyze's user tracking API.

Part 1: Set up CookieYes

Step 1: Create a CookieYes account and configure your banner

Sign up at cookieyes.com and create a new website. CookieYes will ask for your site URL and generate an installation script tied to your account. Banner appearance, consent categories, and policy links can all be configured from the CookieYes dashboard before you install anything on the site.

Step 2: Get your installation script

From the CookieYes dashboard, navigate to Advanced Settings and click "Get Installation Code." Copy the script tag provided. It will look something like this:

<script id="cookieyes" type="text/javascript" src="https://cdn-cookieyes.com/client_data/[your-unique-id]/script.js"></script>

Step 3: Add the CookieYes script to Webflow

  1. In your Webflow project, open Site Settings from the dashboard.
  2. Click the Custom Code tab.
  3. Paste your CookieYes script tag into the Head Code section.
  4. Click Save, then Publish the site.

To verify the installation, return to the CookieYes dashboard and click Verify on the setup screen. A successful installation returns a confirmation message.

Part 2: Wire CookieYes to Webflow Analyze

CookieYes fires JavaScript events when the consent banner loads and when a user updates their consent preferences. Webflow Analyze exposes a wf object with two methods — wf.allowUserTracking() and wf.denyUserTracking() — that control whether enhanced tracking is active for a given session.

The code below listens for both CookieYes events and calls the appropriate Webflow Analyze method based on whether the user has consented to the analytics category.

Step 1: Add the event listener code to Webflow

In Webflow's Custom Code settings, paste the following into the Footer Code section. Adding it to the footer rather than the head ensures the wf object is available when the script runs.

<!-- Start cookieyes banner | [Insert initials and date] -->
<script id="cookieyes" type="text/javascript" src="[insert custom source URL from CookieYes Installation code]">
</script>
<!-- End cookieyes banner -->

<!-- CookieYes Event Listener | [Insert initials and date] -->
<script>
  // Handle initial page load - check existing consent state via banner load
  document.addEventListener("cookieyes_banner_load", function (eventData) {
    const data = eventData.detail;
    wf.ready(() => {
      if (data.categories.analytics === true) {
        wf.allowUserTracking();
        console.log("Success - existing consent on load");
      } else {
        wf.denyUserTracking();
        console.log("No analytics consent on load");
      }
    });
  });

  // Handle consent updates - when user makes or changes their choice
  document.addEventListener("cookieyes_consent_update", function (eventData) {
    const data = eventData.detail;
    wf.ready(() => {
      if (data.accepted.includes("analytics")) {
        wf.allowUserTracking();
        console.log("Success - consent updated to allow");
      } else {
        wf.denyUserTracking();
        console.log("Consent updated to deny");
      }
    });
  });
</script>
<!-- End CookieYes Event Listener -->

Step 2: Replace the placeholder values

Before publishing, replace [Insert initials and date] with your initials and the implementation date for internal reference. Replace [insert custom source URL from CookieYes Installation code] with the actual script URL from your CookieYes dashboard.

Step 3: Publish and test

Publish your Webflow site, then open your browser's developer console on the live site. On page load, you should see either "Success - existing consent on load" or "No analytics consent on load" depending on any previously stored consent preferences.

Updating consent through the banner should trigger the corresponding "consent updated" log. If those messages appear as expected, the integration is working correctly.

How the code actually works

The implementation covers two distinct scenarios.

The cookieyes_banner_load event fires on every page load and reports the user's current consent state, including any previously stored preferences. The listener checks whether the analytics category is set to true and calls the appropriate Webflow Analyze method inside wf.ready(), which ensures the call only happens after the wf object is initialized.

The cookieyes_consent_update event fires when a user actively makes or changes a consent choice. This listener checks whether analytics is in the accepted array and updates the Webflow Analyze tracking state accordingly. This covers the case where a user who initially declined later changes their mind, as well as a user who previously accepted and then withdraws consent.

Wrapping both calls inside wf.ready() prevents race conditions where the listener fires before Webflow Analyze has finished loading on the page.

FAQ

Does Webflow Analyze require a consent banner?

Webflow Analyze's core pageview and session tracking is cookieless, so it generally doesn't require consent under GDPR or CCPA for basic analytics. But if you enable the user tracking API with wf.allowUserTracking() for more detailed behavioral data, that enhanced tracking should be gated behind explicit user consent. The CookieYes integration in this guide handles that gating automatically.

Does CookieYes block other scripts like Google Analytics automatically?

Yes, with proper configuration. CookieYes uses script blocking to prevent third-party tracking scripts from firing until the user has consented to the relevant category. Scripts added through Webflow's custom code settings or via a tag manager need to be registered in CookieYes so the platform knows which category they belong to and whether to block them on initial load. Check the Cookie Management section of your CookieYes dashboard to confirm all tracking scripts on your site are accounted for.

What happens if the CookieYes banner hasn't loaded yet when a user lands on the page?

The cookieyes_banner_load event handles this. It fires once CookieYes has initialized and determined the current consent state — whether that's a first-time visit with no stored preferences or a returning user with previously saved choices. Wrapping the Webflow Analyze calls inside wf.ready() adds a further layer of protection against timing issues during page load.

Will this integration work in Webflow's Designer or Preview mode?

No. Webflow Analyze and published custom code don't run in the Designer or in staging preview. Test the integration on the published live site or on a staging domain with a published version of the site.

What privacy regulations does this setup support?

When properly configured, CookieYes supports GDPR (EU and UK), CCPA, CPRA, and several other regional privacy frameworks. Compliance depends on correct banner configuration, accurate cookie categorization, and proper script blocking. Consult a legal professional for advice specific to your jurisdiction and use case. CookieYes also supports Google Consent Mode v2 if you're running Google Ads or Analytics and need to pass consent signals to Google's platforms.

Is Webflow Analyze available on all Webflow plans?

Webflow Analyze is available on paid Webflow site plans. Check Webflow's current pricing page for the most up-to-date information, since plan features get updated periodically.

What's the difference between cookieyes_banner_load and cookieyes_consent_update?

The cookieyes_banner_load event fires on every page load and reflects whatever consent state is currently stored for that user — whether they made a choice previously or not. The cookieyes_consent_update event fires only when the user actively accepts, rejects, or modifies their preferences through the banner.

Both events are needed. One restores the correct state on return visits. The other responds to live preference changes during a session.

Can I use this same approach with other consent management platforms?

The logic transfers to any CMP that fires JavaScript events on consent state changes. The specific event names (cookieyes_banner_load, cookieyes_consent_update) and the consent data structure are specific to CookieYes, so you'd need to check your CMP's documentation for the equivalent events and adjust the listener code accordingly. The Webflow Analyze side — wf.allowUserTracking() and wf.denyUserTracking() — stays the same regardless of which CMP you use.

Resources and Further Reading

CookieYes Documentation

The official CookieYes guide for Webflow covers banner setup and installation in detail: cookieyes.com/documentation/cookie-banner-webflow. That guide doesn't currently cover the Webflow Analyze integration, which is exactly what the custom event listener code in this article addresses.

Webflow Analyze

Webflow's documentation for Analyze, including the user tracking API, is available in Webflow University and the Webflow Help Center at webflow.com.

Google Consent Mode v2

If you're running Google Analytics 4 or Google Ads alongside Webflow Analyze, CookieYes supports Google Consent Mode v2. Configuration is handled within the CookieYes dashboard under Integrations.

Need Help With Your Webflow Setup?

Greater is a Webflow Enterprise studio that has handled this kind of implementation across dozens of client projects. If you're working through a Webflow build, migration, or analytics configuration and want a team that knows the platform thoroughly, get in touch with Greater to talk through your project. Whether it's a CookieYes integration, a full Webflow Analyze configuration, or a broader WebOps engagement, we're glad to help.

More content

Learn about other things on our mind

Button Text

Squarespace to Webflow: Complete Guide + Migration Services

Subheading
Button Text

The 3D tool that finally feels like it was built for UI designers (with one big catch)

Subheading
Button Text

Why your website redesign will fail (even if the design is perfect)

Subheading