Contents
Levene's Test
Levene's Test checks whether two or more groups have equal variances (homogeneity of variance). Use it to verify the equal-variance assumption before running ANOVA or t-tests.

Quick Hits
- •Tests whether two or more groups have equal variances
- •Used to check the homogeneity of variance assumption for ANOVA and t-tests
- •More robust than Bartlett's test when data is not perfectly normal
- •Null hypothesis: all group variances are equal (rejecting means unequal)
- •Three variants: based on mean, median (Brown-Forsythe), or trimmed mean
The StatsTest Flow: Difference or Goodness of Fit >> Testing Distribution Assumptions >> Do groups have equal variance?
Not sure this is the right statistical method? Use the Choose Your StatsTest workflow to select the right method.
What is Levene's Test?
Levene's Test is a statistical test that assesses whether the variances of a continuous variable are equal across two or more groups. It is the most commonly used test for the homogeneity of variance assumption required by ANOVA and the standard t-test.
The test works by computing the absolute deviations of each observation from its group center (mean, median, or trimmed mean), then performing a one-way ANOVA on these deviations. A significant result indicates the group variances are not equal.
Levene's Test is also called Levene's Test for Equality of Variances. The median variant is called the Brown-Forsythe Test.
Assumptions for Levene's Test
The assumptions include:
- Continuous Data
- Two or More Independent Groups
- Independent Observations
Continuous Data
The variable being tested must be continuous. Levene's test is not meaningful for categorical or binary outcomes.
Two or More Independent Groups
You need at least two groups to compare. The groups must be independent of each other.
Independent Observations
Observations within each group must be independent.
When to use Levene's Test?
- You want to check the equal-variance assumption before running ANOVA or a t-test
- Your data may not be perfectly normal (Levene's is robust to non-normality)
- You have two or more independent groups
Levene's vs. Bartlett's Test
Bartlett's test is an alternative variance equality test that is more powerful when data is normal but very sensitive to non-normality. Use Levene's test (especially the median variant) as the default because most real-world data is not perfectly normal.
If you are testing normality itself, use the Shapiro-Wilk Test. If you are testing whether your data follows a specific distribution, use the Kolmogorov-Smirnov Test.
Levene's Test Example
Before running a One-Way ANOVA comparing customer satisfaction scores across three pricing tiers (basic, pro, enterprise), you check whether the variance of satisfaction scores is similar across tiers.
Levene's test (median variant): F(2, 297) = 1.34, p = 0.26.
Since p > 0.05, the equal-variance assumption holds and you proceed with the standard ANOVA. If it had been significant, you would use Welch's ANOVA or the Kruskal-Wallis Test instead.
References
- https://www.itl.nist.gov/div898/handbook/eda/section3/eda35a.htm
- https://online.stat.psu.edu/stat501/lesson/10/10.4
Frequently Asked Questions
What should I do if Levene's test is significant?
Which variant of Levene's test should I use?
Should I always test variance equality before a t-test?
Key Takeaway
Levene's test is the standard method for testing the equal-variance assumption. Use the median (Brown-Forsythe) variant for robustness. However, consider using Welch's t-test or Welch's ANOVA by default, which avoid the need for a preliminary variance test altogether.