Bayes Factor Calculator

A Bayes factor measures how much your data favor one hypothesis over another, like saying the evidence is 5 times stronger for an effect than for no effect. Enter a test statistic or summary stats to get the BF, an evidence label (anecdotal to decisive), and the equivalent frequentist p-value side by side.

i New to Bayes factors? Read the 4-min primer

What a Bayes factor is. The Bayes factor BF₁₀ is the ratio of the data’s marginal likelihood under the alternative H₁ to its marginal likelihood under the null H₀. Read it as “the data are BF₁₀ times more likely under H₁ than under H₀.” A BF of 10 says the evidence favours H₁ ten-to-one; a BF of 0.1 says the evidence favours H₀ ten-to-one. There is no “significance” threshold: the BF is the evidence, full stop.

How to read the number. Jeffreys and Wagenmakers give a rough ladder: above 100 is extreme, 30 to 100 very strong, 10 to 30 strong, 3 to 10 moderate, 1 to 3 anecdotal. Below 1, mirror the labels for evidence in favour of the null. The big swing happens between 3 and 10; below 3, treat the evidence as weak no matter which side it leans.

Picking a prior. The Bayes factor needs a prior on the effect under H₁. The JZS Cauchy is the standard default with scale 0.707 (medium). A wider scale of 1.0 or 1.414 expects bigger effects and so penalises small ones more harshly under H₁; a narrower 0.5 expects smaller effects and rewards them. Always check sensitivity by varying the scale; the plot below does this for you.

BF versus p-value. A p-value asks “how surprised would H₀ be by data this extreme or more?”. A Bayes factor asks “which hypothesis predicted the data better?”. P-values reject; Bayes factors quantify. They can disagree, especially at large n: a tiny effect may be highly significant yet have a Bayes factor near 1, because both H₀ and H₁ predict it about equally well.

No data leaves your browser · Verified against R's BayesFactor package · Free

Try a real-world example to load.

📝 Scenario

BF₁₀
·
Recap
R code COPY-READY
R Reproduce in R
Sensitivity to prior INTERACTIVE
Bayes factor vs Cauchy scale r (log-y)
Inference

We computed how strongly your data favor the alternative hypothesis over the null, expressed on the Jeffreys evidence scale.

Read more The Bayes factor math, end to end
BF₁₀ = ∫ p(t | g, ν) π(g) dg / p(t | g=0, ν) π(g) = inverse-gamma(0.5, r²/2)
JZS for the t-test (Rouder 2009). Effect size δ sits on a Cauchy(0, r) prior, equivalently δ | g ~ N(0, g) with g ~ inverse-gamma. The numerator marginalises the noncentral t density over g; the denominator is the central t density at the observed t. We integrate on a log-g grid by Simpson’s rule with a wide range; for the t test the integrand is unimodal and the rule is accurate to many digits.
nᵉ = n (one-sample), n₁ n₂ / (n₁+n₂) (two-sample) ν = n−1 (one-sample), n₁+n₂−2 (two-sample)
Effective n and df. The marginal likelihood depends on n through nᵉ (effective sample size) and on the t distribution’s df ν. Welch is approximated by using the pooled df and effective n; for moderate-to-large n the BF is robust to the unequal-variance correction. For the paired design, treat it as a one-sample t on the differences with n equal to the number of pairs.
P(H₁ | data) = BF₁₀ / (1 + BF₁₀) with 50/50 priors
Posterior probability. If you start out 50/50 between H₀ and H₁, the posterior probability of H₁ is BF₁₀ / (1 + BF₁₀). A BF of 10 puts you at 91% on H₁; a BF of 3 only 75%. With unequal priors, multiply BF by the prior odds to get posterior odds, then convert to a probability.
Correlation: stretched-beta on r BF₁₀ = ∫ p(r | ρ) π(ρ; κ) dρ / p(r | ρ=0)
Correlation BF (Ly, Verhagen & Wagenmakers 2016). The stretched-beta prior on the population correlation ρ assigns mass on (−1, 1) controlled by the width κ (medium κ = 1/3). There is a closed-form analytic result via a Gauss hypergeometric function, so no numerical integration is needed. This reproduces BayesFactor::correlationBF() to machine precision.
Two-proportion: independent-multinomial 2x2 table (Gunel & Dickey 1974) BF₁₀ = product of Dirichlet marginal likelihoods, concentration a
Two-proportion BF. This is the independent-multinomial contingency-table Bayes factor: each row (group) is a multinomial with a Dirichlet prior of concentration a, and H₀ forces the two rows to share column proportions. It has a closed form in log-Gamma functions, so it is exact. With a = 1 (uniform, the default) this matches BayesFactor::contingencyTableBF(sampleType = "indepMulti") exactly.
ANOVA / regression (Liang 2008): R² = F · df1 / (F · df1 + df2) BF₁₀ = ∫ (1+g)^((N−p−1)/2) (1 + g(1−R²))^(−(N−1)/2) π(g) dg π(g) = inverse-gamma(1/2, N r² / 2)
ANOVA and linear regression BF. The same JZS / Zellner-Siow g-prior covers both, computed from R² and the degrees of freedom by integrating the unimodal integrand on log(g). For regression this is exact: R² is sufficient, so it equals BayesFactor::regressionBF() to machine precision. For ANOVA it gives the omnibus “group means vs null” BF via the same R² route; anovaBF() on raw data uses a slightly different effect prior, so its number differs by roughly 10–20%. Either way the p-value and BF answer different questions.
Caveats When this is the wrong tool
If you have…
Use instead
A complex hierarchical or mixed model
The JZS prior is built for fixed-effect designs. For mixed effects, the BayesFactor::lmBF() family handles random terms with explicit variance priors; for anything bespoke, fit in Stan or brms and compute BFs by bridge sampling.
Tiny n (under 5 per group)
Numerical integration is fine but the prior is doing most of the work. Report the prior, run the sensitivity plot, and treat the BF as descriptive rather than decisive.
One-sided hypotheses
This tool uses two-sided priors. For a directional H₁ (effect > 0), truncate the Cauchy at zero and renormalise the integral; in R, pass nullInterval = c(0, Inf) to ttestBF().
A planning question (sample size)
BFs are post-hoc evidence summaries. For prospective design, compute the Bayes factor design analysis (BFDA) by simulation, or fall back on classical power. The Power analysis tool handles the latter.
Strong informative priors from the literature
JZS is a default, not a substitute for the right prior. If you know the field-level effect-size distribution, encode it directly with a normal or t prior on δ and integrate accordingly.
Categorical / count outcomes beyond 2x2
Use a Bayesian contingency-table model or a Poisson Bayes factor; the JZS construction does not generalise to counts without extra structure.
Further reading

Every Bayes factor is verified against the R BayesFactor package (0.9.12-4.8): t-tests via ttest.tstat, regression and ANOVA via linearReg.R2stat, correlation via the exact Ly et al. analytic BF, two-proportion via the independent-multinomial contingencyTableBF. t and g-prior integrals use a mode-centred composite Simpson rule on log(g); the sensitivity curve sweeps the prior scale live.

Frequently asked questions

What does a Bayes Factor of 10 mean?

A Bayes Factor (BF10) of 10 means the data are 10 times more likely under the alternative hypothesis than under the null. On the Jeffreys scale this is "strong" evidence for the alternative. BF10 between 1 and 3 is anecdotal, 3 to 10 is moderate, above 100 is decisive. Interpret cautiously when priors are weakly justified.

How is a Bayes Factor different from a p-value?

A p-value tells you how surprising your data would be if the null were true; it cannot quantify evidence FOR the null. A Bayes Factor compares two models directly and can support either side, including "the data favor the null." Use BF when you need to claim no effect, not just fail to reject.

Which prior should I use for a Bayes Factor t-test?

A Cauchy prior on the standardized effect size with scale 1/sqrt(2) (about 0.707) is the default for the BayesFactor R package and reflects medium-sized effects. Use a wider scale if you expect large effects, narrower if you expect small ones. The calculator shows how BF10 changes as you vary the prior.