Bell Statistics

What is a prior distribution?

A prior distribution encodes what you believed about an effect before seeing the data. It is combined with the evidence to produce the posterior, and choosing it is a modelling decision that has to be defended rather than a technicality to be defaulted through.

Also called
prior, informative prior, uninformative prior, prior belief
Allon Korem

Written by Allon Korem

Chief Executive Officer

Last updated

In plain English

Every Bayesian analysis starts with a prior: a probability distribution over the effect, representing what was believed before the experiment. Bayes' theorem combines it with the data to produce the posterior, and everything reported afterwards depends on both. The prior is the part that has no frequentist equivalent, and it is where most of the argument about Bayesian methods lives.

Priors range from informative to deliberately vague. An informative prior says something specific — past experiments on this surface produced effects between −2% and +5%, centred near zero — and it can be built from a programme's own history rather than invented. A weakly informative prior rules out the absurd while staying open: effects beyond ±50% are implausible for a button colour. A flat or uninformative prior tries to say nothing at all, and mostly reproduces the frequentist answer in different notation.

The honest case for an informative prior is that it is usually true and usually ignored. If ninety of your last hundred experiments produced effects under 3%, then a claimed 40% lift should be discounted, and a prior does that automatically and transparently. A frequentist analysis discards that history entirely and treats each experiment as though nothing were known. Where the history is real, the prior is an asset rather than a contamination.

The dishonest case is a prior chosen because it produces the desired conclusion. A prior centred on a large positive effect will report a large positive effect from thin data, and nothing in the output announces that the conclusion came from the assumption. This is why the prior must be stated, justified from something external, and fixed before the data arrives — the same discipline that makes a pre-registered hypothesis meaningful.

The practical safeguard is a sensitivity check. Rerun the analysis under two or three defensible priors — a flat one, an empirical one from history, a sceptical one centred at zero — and see whether the conclusion holds. If it does, the data is doing the work and the prior is a detail. If it flips, the prior is doing the work, which is worth knowing and worth saying out loud rather than reporting one number.

The formula

Where the prior sits in the calculation, and the conjugate case that makes its influence directly interpretable.

Its role
posterior ∝ likelihood × prior

Multiplied by the evidence rather than replaced by it. Its influence fades as the data accumulates.

The conjugate case for a rate
Beta(α, β) prior + s successes in n trials → Beta(α + s, β + n − s)

Updating is addition. This is why Beta-Binomial is the standard setup for conversion metrics.

Prior strength, made concrete
Beta(α, β) carries the weight of α + β prior observations

Beta(2, 38) is like having seen 40 users convert at 5%. That is the number to sanity-check against your sample.

The sensitivity check
rerun under flat, empirical and sceptical priors

A conclusion that survives all three is data-driven — see the proportion confidence interval calculator for the frequentist comparison.

Worked example

A conversion test on a 5% baseline observes 62 conversions in 1,000 users for the variant against 50 in 1,000 for control. The analysis is run under three priors to see how much the choice matters at this sample size.

Observed
6.2% vs 5.0%, n = 1,000 per arm
Flat prior, Beta(1,1)
P(variant better) = 89.4%
Empirical prior from 200 past tests
effects centred at 0, SD 2.5% relative
Under the empirical prior
P(variant better) = 76.1%
Sceptical prior, Beta(50, 950) per arm
P(variant better) = 68.8%
Frequentist p-value (two-sided)
0.226

The same data supports 89%, 76% or 69% confidence that the variant is better, depending entirely on the prior.

The spread across those three numbers is the finding, and it is what a single reported figure would have concealed. At 1,000 users per arm the data is thin enough that the prior still carries real weight — the flat prior lets the observed 24% relative lift speak for itself, while the empirical prior correctly notes that lifts that large are rare in this programme and pulls the estimate back. The empirical version is the defensible one here, because it comes from 200 actual experiments rather than from a default. Worth noticing the last row: the frequentist p-value of 0.226 would have been reported as "no significant difference", which is a third framing again. None of these is wrong; they answer different questions. What would be wrong is running all three and reporting whichever sounded best, which is why the prior has to be fixed before the data arrives.

Common misconceptions

Using a prior means injecting your opinion into the analysis.
It can be, and it need not be. A prior built from a programme's own history of effect sizes is an empirical quantity. The genuine risk is a prior chosen to produce a desired result, which is why it should be fixed in advance and justified from something external — the same discipline a pre-registered hypothesis requires.
A flat prior is neutral and therefore safe.
It is a specific claim — that every effect size is equally plausible, including a 500% lift — and that claim is usually false and sometimes consequential. It also discards genuine information: if your last hundred experiments all produced effects under 3%, treating a 40% lift as equally likely is not neutrality but a decision to ignore what you know.
With a large sample the prior stops mattering, so it can be chosen carelessly.
It washes out when the data is strong relative to the prior's strength, which is common and not universal. Rare events, small samples and strongly informative priors all keep it influential. The way to know rather than assume is a sensitivity check across two or three defensible priors.

Frequently asked questions

How do I choose a prior?
From your own experiment history where it exists: the distribution of effect sizes across past tests on similar surfaces is an empirical prior and is defensible precisely because it was not invented for this analysis. Where no history exists, use a weakly informative prior that rules out absurd effects while staying open, and report a sensitivity check across alternatives.
How strong is my prior in practice?
For a Beta prior on a rate, α + β is the number of prior observations it is worth. Beta(2, 38) carries the weight of 40 users; against a sample of 50,000 it is negligible, and against a sample of 100 it dominates. Computing that number and comparing it against your actual sample is the quickest way to know whether the prior is a detail or the conclusion.
How do I check whether the prior is driving my result?
Rerun the analysis under a flat prior, an empirical one from history, and a sceptical one centred at zero, and compare the conclusions. Agreement means the data is doing the work. Disagreement means the prior is, which is not automatically wrong — a sceptical prior correctly discounting a wild result is the system working — but it must be reported rather than hidden behind a single number.

Related terms

  • Bayes' theorem

    Evidence updates a belief, it does not replace one — and ignoring the base rate is how a strong test gives a weak conclusion.

  • Bayesian A/B testing

    Friendlier output, the same underlying evidence — and it does not fix peeking, which is why most teams adopt it.

  • Credible interval

    The interval that means what everyone thinks a confidence interval means — conditional on a prior somebody chose.

  • Posterior distribution

    The whole distribution of what the effect might be — which is why Bayesian reports can answer questions a p-value cannot.

Calculate it

  • A/B test sample size

    Size a two-proportion experiment before you launch, then read the lift and its interval once it lands.

  • Proportion confidence interval

    A defensible interval around one rate — Wilson, Agresti-Coull, Jeffreys and Clopper-Pearson, side by side.

Knowing the term is the easy part

Applying it to a live measurement problem is the part that goes wrong. If you are designing an experiment, reading a result you do not trust, or trying to work out what your marketing actually caused, that is the work we do.

References