Mida + Google Analytics 4 integration

Send Mida A/B test exposure and conversion events to GA4 for advanced analysis alongside the rest of your traffic data.

Analytics & Data Data out Client-side Works with Mida A/B Testing & Personalization

About Google Analytics 4

Google Analytics 4 (GA4) is Google's flagship event-based web and app analytics platform, used by millions of sites to measure traffic, conversions, and user journeys. GA4 is built around custom events and audiences, which makes it a natural home for A/B test reporting alongside the rest of your acquisition and behavior data.

How the Google Analytics 4 integration works

Mida automatically detects either the gtag function or the dataLayer array on your page and forwards three Mida events — mida_pageview, mida_execute, and mida_conversion — every time a visitor is exposed to a variant or hits a goal. Each event carries the test ID, test name, variant, and Mida user ID so you can build GA4 explorations and audiences segmented by experiment.

Requirements

  • GA4 configuration tag installed on the page (gtag.js or GTM).
  • Mida tracking code installed on the page.

Use cases

Report A/B test impact in GA4 explorations

Use the test name and variant as dimensions in a free-form GA4 exploration to compare key metrics — engaged sessions, scroll depth, conversions, revenue — across variants without leaving GA4.

Build GA4 audiences from Mida variants

Create a GA4 audience like 'Saw variant B of homepage hero' from the mida_execute event. Re-target that audience with Google Ads or sync it to Search Ads 360 for downstream optimization.

Validate Mida conversions against GA4 conversions

Mark mida_conversion as a key event in GA4 and compare counts to your existing GA4 conversion. This is the fastest way to confirm Mida and GA4 agree on attribution before you trust a winner.

Debug experiments with GA4 DebugView

Enable debug mode and watch mida_pageview / mida_conversion stream into GA4 DebugView in real time so you can confirm variant assignment and goal firing on your own browser before launching.

Shared data

Mida and Google Analytics 4 exchange the following events:

Event Direction Description
mida_pageview Data out Fired on every page after the visitor is bucketed into a variant.
mida_execute Data out Fired only when a test campaign actually executes on the current page.
mida_conversion Data out Fired when the visitor reaches a Mida conversion goal.

Frequently asked questions

Does Mida send any personally identifiable information to GA4?

No. Mida only sends the test ID, test name, variant ID, an anonymous Mida user ID, and a timestamp. No emails, names, or IPs leave Mida.

Do I need GTM or can I use gtag.js directly?

Either works. Mida detects whichever is present on the page — if both are installed it prefers the dataLayer push so GTM-based reporting setups continue to work.

Will the integration affect my GA4 sampling or quota?

Mida sends one event per visitor per page, plus one per conversion. For typical sites this is a tiny fraction of GA4's free-tier quota and does not trigger sampling.

Can I use Universal Analytics instead?

Universal Analytics has been sunset by Google. Mida only supports GA4.

Ship A/B tests 10x faster — connected to your stack

Mida is the lightweight A/B testing and personalization platform that integrates with the tools you already pay for.