Last updated
Google Analytics 4 (GA4) is Google's event-based analytics platform for websites and apps. In an A/B test it is the reporting system you send experiment events to, not the system that assigns visitors to a variant.
Google Analytics 4 (GA4) is Google's event-based analytics platform for websites and apps. In an A/B test it is the reporting system you send experiment events to, not the system that assigns visitors to a variant.
GA4 replaced Universal Analytics. A hit is an event with parameters, and audiences are built from those events. That model fits experiment reporting: a variant id can travel as an event parameter next to session, source, and conversion data you already collect. GA4 does not split traffic, stick a visitor to a variant, or rewrite the page. Those jobs belong to the testing tool. Mida's published note on GA4 data is that user and session counts in GA4 are cardinality estimates, so they can disagree with the exact counts in the experiment.
Teams already live in GA4 for acquisition and revenue. Sending exposure and conversion events there lets an analyst compare engaged sessions, conversions, and revenue by variant without exporting a spreadsheet. It also makes a mismatch visible: if Mida and GA4 disagree on conversions, the goal or the tag is wrong and the test should not be called. Using GA4 user counts alone to pick a winner is the failure mode, because those counts are estimates.
A pricing-page test sends mida_execute with the test name and variant on each eligible view, and mida_conversion when the signup goal fires. In a GA4 free-form exploration the variant is a dimension and signups are the metric. Variant B shows more signups. The experimenter still calls the test from Mida's sample size and conversion counts, and uses the exploration to check that the lift is not concentrated in one campaign.
Install a GA4 configuration tag with gtag.js or through Google Tag Manager, install the Mida snippet, and turn on the GA4 integration. Mark mida_conversion as a key event only after a debug session shows the same goal firing in both tools. Build the exploration after the test has the sample you planned. Do not stop the test because an in-progress GA4 card looks decisive.
A common mistake is treating a GA4 user count as an exact sample size. The count is an estimate, and at higher traffic the error can be large enough to reverse which variant looks ahead. Another mistake is creating the GA4 audience after peeking, then using that audience as if it were the randomized assignment.
The GA4 integration detects gtag or dataLayer on the page. If both are present, Mida prefers the dataLayer push so an existing GTM setup keeps working. It then forwards three events:
mida_pageview fires on each page after the visitor is bucketed into a variant.mida_execute fires only when a test actually executes on the current page.mida_conversion fires when the visitor reaches a Mida goal.Each event includes the test id, test name, variant, and an anonymous Mida user id. It does not include an email, a name, or an IP address. You need the GA4 tag and the Mida snippet on the page. Universal Analytics is not supported. One event per visitor per page, plus one per conversion, is how the integration is specified, and that volume is described as a small share of GA4's free-tier quota.
DebugView is the check before launch: watch mida_pageview and mida_conversion arrive while you click through the variant. If GTM already forwards events to GA4, the Google Tag Manager integration is enough and a second GA4 connection is not required. Read why GA4 user counts are a poor source of truth for a test before you let an exploration overrule Mida's counts.

No. GA4 can break a report down by an event parameter such as variant, but it does not bucket visitors, keep them in that bucket, or apply a page change. Mida does the assignment. GA4 is the place those events can be analyzed next to acquisition and revenue data.
Three outbound events: mida_pageview after the visitor is bucketed, mida_execute when a test actually runs on that page, and mida_conversion when a Mida goal is reached. They carry the test id, test name, variant, and an anonymous Mida user id. Emails, names, and IP addresses are not included.
Treat the exploration as a second view, not the source of truth. GA4 estimates user counts, and a Mida write-up of that estimation shows it can be large enough to flip a conclusion. Decide the test from Mida's visitor and conversion counts, then use GA4 to see how that variant lines up with the rest of the journey.
Visual editor, AI-generated variants with MidaGX, redirect testing, and GA4 integration — free forever in the Mida Sandbox. No credit card required.
Still deciding?
A quick screen share on your actual site — no slides, no generic tour. Just your questions answered.
30 min · no commitment · no sales pressure