Skip to main content
← Back to the blog

Guides

Web analytics with consent and GDPR

Published November 14, 2026 · 7 min read

FFlowgrationGUIDESWeb analytics with consentand GDPR

You want to know what each visitor does on your site: which page they read, how far they scroll, where they stop and how they got there. Most analytics tools answer that with cookies and send data to third parties before the person has decided anything. Under GDPR and the EU cookie rules, that doesn't hold up without prior consent.

Flowgration's tracker works the other way round. It does nothing until the visitor says yes. This guide explains what it stores, which mode suits your case and how to set it up without a developer.

What is consent-based web analytics? It means measuring visitor behaviour only after they accept analytics, and keeping only what you need for that purpose. If they don't accept, no cookie is written and no request is sent.

Before consent, the tracker does nothing: no cookies, no browser storage, no requests. After consent it uses two first-party identifiers:

  • _fgv recognises the visitor for 13 months.
  • _fgs groups the pages of one browsing session.

If the visitor withdraws consent, their cookies are deleted and the server removes their events and sessions. That visitor ID is also refused from then on.

The tracker works with your cookie banner. It detects Cookiebot, CookieYes, OneTrust, Complianz and Google Consent Mode v2 automatically. With any other banner, call flowgration('consent', true) once the visitor accepts. If the browser sends Do Not Track or Global Privacy Control, the tracker switches itself off.

Both modes have a place:

Consent mode (default)Cookieless mode
Cookies_fgv and _fgs, only after consentNone
Identifying peopleYes, when a visitor gives their email or submits a formNever
Sessions and bounce rateYesNo: without sessions these metrics stay empty
Traffic sources and UTMYes, per sessionNo: they are computed from sessions
Raw eventsKept for 6, 13 or 26 months, your choiceDeleted after aggregation, within 48 hours at most
Cookie bannerNeeded before the tracker starts measuringNo cookies are set; check with your adviser whether you need one

Pick consent mode if you want full visitor journeys, sessions and form submissions linked to CRM contacts. Pick cookieless mode if you only need to know which pages are read and how they are used (scroll and clicks), with no journeys, no traffic sources and no identification.

What you can measure

  • Page views and, in consent mode, new visitors, landing pages and traffic sources, including the UTM parameters of your campaigns.
  • Scroll depth: how many visitors reach 25, 50, 75 and 100% of each page.
  • Clicks, rage clicks (several quick clicks in the same spot with no effect) and dead clicks (clicks on elements that do nothing).
  • Form submissions: the tracker records which fields a form has, never what anyone typed.
  • Your own events, such as a download or a change to a price table, with flowgration('track', 'event-name').

Two limits to know from the start. The tracker never reads the value of a text field, and you can exclude any element with data-fg-ignore. It doesn't geolocate by IP either: the country comes from the region of the browser's language, so a visitor set to es-ES counts as Spain.

How to set it up in five steps

  1. Create the site. In Settings, Web analytics, add your website and its domains. You get a snippet with your site key.
  2. Paste the snippet on every page, or add it through your tag manager. It loads asynchronously, so it won't hold up the page.
  3. Choose the mode and connect your cookie banner, or call the consent function from your code.
  4. Update your cookie policy. Declare _fgv and _fgs, their purpose and how long they last. Settings includes sample text in Spanish and English you can adapt, and your adviser or DPO should review it. You also pick the retention for raw events: 6, 13 or 26 months.
  5. Check the live panel. Open your site in a private window, reject cookies and browse. Then accept in a second private window and browse again. Only the second visit should appear.

Frequently asked questions

Do I need a cookie banner?

In consent mode, yes. The tracker only writes cookies after the visitor accepts, so you need a banner for it to start measuring. In cookieless mode no cookies are written, but confirm with your adviser what your situation requires.

Which cookies do I need to declare?

Two: _fgv, which lasts 13 months, and _fgs, a session cookie. Say what each one is for and how long the data is kept.

Can I delete a visitor's data?

Yes. When someone withdraws consent, their events and sessions are deleted. If a contact asks for their data, you can export or delete only their web data, without deleting the contact record.

Which plan do I need?

Anonymous page analytics is included from the Essential plan, with 50,000 events a month. Identifying visitors and viewing heatmaps needs the Growth plan. When the monthly limit is reached, new events are dropped and the rest of your account is not affected.

If you want to test it first, the 14-day trial of any paid plan has everything unlocked and doesn't ask for a card. Check the plans and limits and the web analytics page first. For the wider legal picture, read the GDPR guide for CRMs.

Build your WooCommerce CRM in 60 seconds

Flowgration turns your store's orders into a living CRM and runs email, SMS and WhatsApp on autopilot. Free up to 500 contacts.

Start free