EUComply

Google Analytics and GDPR: Is Your Tracking Legal?

Updated August 2026. Google Analytics is on millions of websites — and it is one of the most common sources of GDPR problems for small businesses. The short answer to "is Google Analytics GDPR-compliant?" is: it can be, but only if visitors consent before the script loads. Most sites get this wrong.

The rule: consent comes first

Two pieces of EU law apply:

Together they mean: the GA tag must not fire until the visitor clicks "Accept." A cookie banner that appears at the same time as the tracking script — or after it — does not count. The data was already collected.

What happens when you get it wrong

This is not theoretical:

CaseIssueOutcome
Austrian DSB rulings (2021–)GA transfers IP data to the US without adequate safeguardsDozens of sites found non-compliant
Danish Datatilsynet (2024–2026 practice)Analytics tags firing before consentOrders to block scripts until consent
French CNIL guidanceSame — consent required before measurement cookiesFines up to €20M / 4% turnover under GDPR

Regulators have focused on large sites first, but enforcement against small and mid-sized businesses is growing — and a competitor complaint is enough to trigger an audit of any site.

How to check your own site (2 minutes)

  1. Open your homepage in an incognito window with DevTools open (Network tab). If requests to google-analytics.com, googletagmanager.com/gtm.js, connect.facebook.net, or similar fire before you accept cookies — your tracking loads without consent.
  2. Check your consent platform. A CMP like Cookiebot, Usercentrics, CookieYes or Complianz must be present AND configured to actually block these tags until consent. Many CMPs are installed but set to "notify only."
  3. Run a free automated check. Our scanner detects 12 common trackers and whether a working consent platform is present — no installation needed.

Check any site free

Enter a URL and see which trackers load and whether consent is handled — works on WordPress, Shopify, Wix, Squarespace, Webflow, custom HTML, anything.

Run the free scan →

If you fail: how to fix it

  1. Install a CMP that blocks by default. Configure it so analytics/marketing tags are held back until explicit consent. In Google Tag Manager, use Consent Mode v2 with default state denied.
  2. Set Consent Mode v2 defaults correctly. This code goes before every tag:
    <script>
    gtag('consent', 'default', {
      'ad_storage': 'denied',
      'analytics_storage': 'denied'
    });
    </script>
    Only after the visitor accepts do you call gtag('consent', 'update', {...'granted'}).
  3. Consider consent-less alternatives. Tools like Plausible or Fathom use no cookies and don't collect personal data, so they need no consent banner. Matomo can be configured cookieless too.
  4. Anonymize where possible. Enable IP anonymization and keep data-retention periods short (14 months max is a defensible default).

Common mistakes we see in scans

FAQ

Is Google Analytics banned in Europe?

No. But loading it without prior consent violates GDPR and ePrivacy. With a proper CMP and Consent Mode v2, it is legal.

Do I need consent for anonymous analytics?

Cookieless tools that don't store device identifiers generally fall outside the ePrivacy consent requirement. Standard Google Analytics is not anonymous.

Does this apply outside the EU?

If your site serves visitors from the EU — even from a US company — GDPR applies to those visitors. Location-based consent gating is possible but adds complexity; applying consent EU-wide is simpler and safer.

How do I prove compliance?

Keep consent logs (your CMP does this), document your configuration, and re-scan regularly. EUComply Pro includes monitoring that alerts you when a new tracker appears on your site without consent coverage.

Scan your site now — free, no sign-up

Further reading