Google Meridian is the open-source Bayesian marketing mix model that replaced LightweightMMM, and your GA4 BigQuery export already holds most of what it needs. Running it isn't a data problem, it's a modeling-discipline problem.
Here's how to get Meridian running on your own data, and the parts that decide whether the output is worth trusting.
What Meridian actually is
Meridian is Google's Bayesian MMM framework, written in Python and released as open source, with its first official version out in early 2025. It's the successor to Google's earlier LightweightMMM, which is no longer supported.
Like any MMM, it works top-down on aggregate data, not user-level tracking, so nothing here depends on cookies or consent. That's the whole reason it survives a privacy-first world.
What data it needs from BigQuery
Meridian wants weekly, aggregate data over a couple of years. Your GA4 export gives you the outcome side, and your ad platforms give you the spend side.
- A KPI per week, usually revenue or conversions, aggregated from your GA4 BigQuery export.
- Media spend and, ideally, impressions or clicks per channel per week.
- Control variables: price, promotions, seasonality, and anything else that moves sales.
- Optional but powerful: reach and frequency, and geo-level data if you have it.
The modeling lives in Python, but the aggregation is a BigQuery job you run once and schedule.
Setting it up
Install Meridian into a Python environment with a GPU if you can, because Bayesian sampling is slow on a CPU.
pip install google-meridian
# then, in Python
from meridian.model import model, spec
from meridian.data import load
data = load.CsvDataLoader(
csv_path="weekly_mmm_input.csv",
kpi_type="revenue",
).load()
mmm = model.Meridian(input_data=data)
mmm.sample_prior(500)
mmm.sample_posterior(n_chains=4, n_adapt=500, n_burnin=500, n_keep=1000)
That exports from BigQuery into the shape Meridian expects, then fits the model. The sampling step is where the time goes.
Calibration is the step people skip
An MMM on its own is a sophisticated correlation. What turns it into a measurement is calibration: feeding it priors from a real incrementality test, like a geo experiment or a conversion lift study.
Meridian supports ROI priors for exactly this. Give one channel's true incremental ROI from an experiment, and the model anchors the rest to something real instead of guessing from history alone.
Reading the output
Once it's fit, Meridian gives you channel contributions, ROI by channel, and response curves that show diminishing returns. The response curves are the useful part, because they tell you where the next dollar is wasted, not just where the last one went.
Then the budget optimizer proposes an allocation that maximizes your KPI within constraints you set.
Where it bites
- Too little history: under about two years of weekly data, the model can't separate channels from seasonality.
- No calibration, so you ship a confident number with no ground truth behind it.
- Garbage spend data, especially channels with flat or missing spend, which the model can't learn from.
- Treating the point estimate as fact and ignoring the credible intervals Bayesian output gives you.
Make it a habit, not a heroic quarterly project
The old knock on MMM was that a consultant took a quarter to deliver one already-stale model. With Meridian in your own environment, schedule the BigQuery aggregation weekly and re-fit on a cadence, so the model tracks reality instead of describing last spring.
Re-run a calibration experiment periodically too. A channel's true ROI drifts as auctions and creative change, and a prior from two years ago is barely better than a guess.
Google Meridian runs on the data you already export to BigQuery, so the barrier was never access, it was discipline. Feed it clean weekly history, calibrate it against a real experiment, and read the intervals, not just the number, and you get an MMM you can actually defend.
Want a stronger data analyst role or a raise? Grab the FREE Product Analyst Playbook and get the exact roadmap to your next offer.
