Skip to contentScholarGate
LibraryBookshelfDeskReview StudioAssistant
Sign in
On this page
IntuitionHow it worksWhen to use itStrengths & limitationsCommon pitfallsApplicationsFrequently asked🔒 Read the full methodSourcesRelated methods
Cite this pageSpotted an issue on this page? Report or suggest a fix →
Home›Statistics›Kolmogorov-Smirnov Test
Hypothesis test

Kolmogorov-Smirnov Test

Kolmogorov-Smirnov Goodness-of-Fit Test · Also known as: KS test, K-S test, one-sample KS test, Kolmogorov-Smirnov Testi

The Kolmogorov-Smirnov (KS) test is a nonparametric goodness-of-fit test that assesses whether a sample comes from a specified theoretical distribution, such as the normal or exponential. First formalised by Andrey Kolmogorov in 1933 and further developed by Nikolai Smirnov in 1948, it compares the empirical cumulative distribution function of the observed data against a target theoretical CDF and quantifies their maximum absolute deviation.

ScholarGate
  1. Hypothesis test
  2. v1
  3. 4 Sources
  4. PUBLISHED
Cite this page →
Tools & resources
Download slides
Learn & explore

Read the full method

Members only

Sign in with a free account to read this section.

Sign in

Method map

The neighbourhood of related methods — select a node to explore.

Kolmogorov-Smirnov Test
Lilliefors TestTwo-Sample Kolmogorov-Sm…Descriptive StatisticsRuns Test

When to use it

Apply the KS test when you need to verify whether a continuous variable follows a specific theoretical distribution before proceeding with parametric methods that require normality or another distributional form. The variable must be continuous; the test is not suitable for discrete or ordinal data. A minimum sample size of around 20 is advisable, but the test loses power relative to Shapiro-Wilk for detecting departures from normality in large samples (roughly n ≥ 50). When the distribution parameters are estimated from the data rather than specified in advance, the Lilliefors correction should be applied, because standard KS critical values are too conservative in that situation.

Strengths & limitations

Strengths
  • Fully nonparametric: makes no assumptions about the shape of the underlying distribution.
  • Works with the complete continuous CDF, so no arbitrary binning of data is required.
  • Sensitive to differences in the entire distribution, including tails and location shifts.
  • Conceptually transparent and easy to visualise as a gap between two CDF curves.
Limitations
  • Less powerful than Shapiro-Wilk for detecting non-normality, especially in larger samples.
  • Not valid for discrete or ordinal variables.
  • When distribution parameters are estimated from the sample, standard critical values are anticonservative unless the Lilliefors correction is applied.
  • Equally sensitive across all parts of the distribution, so it may miss concentrated departures near the tails that specialised tests such as Anderson-Darling would detect.

Frequently asked

How does the KS test differ from the Shapiro-Wilk test for normality?

Both test whether data are normally distributed, but they differ in approach and power. Shapiro-Wilk is designed specifically for normality and is generally more powerful than the KS test, especially for small to moderate samples (n ≤ 50). The KS test is more general — it can test against any fully specified continuous distribution, not just normal — but this generality comes at the cost of lower power for the normality case.

Can I use the KS test when I estimated the mean and standard deviation from my data?

Not with the standard version. When you estimate the distribution parameters from the same sample you are testing, the critical values are too conservative (too lenient), meaning you will reject less often than you should. In this common situation, use the Lilliefors test, which adjusts the critical values specifically for estimated normal-distribution parameters.

What is the difference between the one-sample and two-sample KS test?

The one-sample KS test compares a single empirical CDF against a theoretical CDF that is fully specified in advance. The two-sample KS test compares the empirical CDFs of two independent samples against each other to decide whether they were drawn from the same population distribution, without specifying what that distribution is.

Does the KS test work for ordinal or count data?

No. The theoretical justification of the KS statistic relies on the data being continuously distributed, so the empirical CDF is a true staircase that can be compared point-by-point against a smooth theoretical curve. For ordinal or count data, the discreteness violates this assumption and the reported p-values will be incorrect; use chi-square goodness-of-fit or appropriate discrete tests instead.

Sources

  1. Kolmogorov, A. N. (1933). Sulla determinazione empirica di una legge di distribuzione. Giornale dell'Istituto Italiano degli Attuari, 4, 83–91. link ↗
  2. Smirnov, N. V. (1948). Table for estimating the goodness of fit of empirical distributions. Annals of Mathematical Statistics, 19(2), 279–281. DOI: 10.1214/aoms/1177730256 ↗
  3. Massey, F. J. (1951). The Kolmogorov-Smirnov test for goodness of fit. Journal of the American Statistical Association, 46(253), 68–78. DOI: 10.2307/2280095 ↗
  4. Conover, W. J. (1999). Practical Nonparametric Statistics (3rd ed.). Wiley. ISBN: 978-0471160687

How to cite this page

ScholarGate. (2026, June 1). Kolmogorov-Smirnov Goodness-of-Fit Test. ScholarGate. https://scholargate.app/en/statistics/kolmogorov-smirnov

Related methods

Lilliefors TestTwo-Sample Kolmogorov-Smirnov Test

Which method?

Set this method beside its closest kin and read them side by side — the library lays the books on the table; the choice is yours.

  • Lilliefors TestStatistics↔ compare
  • Two-Sample Kolmogorov-Smirnov TestStatistics↔ compare
Compare side by side →

Referenced by

Descriptive StatisticsRuns Test

Similar methods

Two-Sample Kolmogorov-Smirnov TestLilliefors TestAnderson-Darling TestShapiro-Wilk testGoodness-of-FitVan der Waerden TestKernel Density EstimationKruskal-Wallis test

Related reference concepts

Data Distribution and NormalityNonparametric StatisticsRank-Based MethodsKaplan-Meier Survival CurvesPermutation TestsStatistical Hypothesis Testing

Spotted an issue on this page? Report or suggest a fix →

ScholarGate — Kolmogorov-Smirnov Test (Kolmogorov-Smirnov Goodness-of-Fit Test). Retrieved 2026-07-21 from https://scholargate.app/en/statistics/kolmogorov-smirnov · Dataset: https://doi.org/10.5281/zenodo.20539026
Quick facts
Originator
Andrey Nikolaevich Kolmogorov; Nikolai Vasilyevich Smirnov
Year
1933
Family
Hypothesis test
Type
Nonparametric goodness-of-fit test
Parametric
No
Outcome
continuous
TestStatistic
D (maximum absolute deviation between empirical and theoretical CDFs)
NullDistribution
Kolmogorov distribution
MinimumSample
20
Difficulty
1
Related methods
Lilliefors TestTwo-Sample Kolmogorov-Smirnov Test
ScholarGate

A content-first reference library for research methods — what each one is, how it works, and where it comes from.

Open data (CC-BY)

Explore

  • Library
  • Search the library…
  • Browse by field
  • Fields
  • Journey
  • Compare
  • Which method?

Reference

  • Subjects
  • Atlas
  • Glossary
  • Methodology
  • Philosophy

Your tools

  • Bookshelf
  • Desk
  • Chat

Company

  • About
  • Pricing
  • Contact
  • Suggest a method

Entries are compiled from published sources for reference. Verifying the accuracy and suitability of any information for your own use remains your responsibility.

© 2026 ScholarGate · A research-method reference library
  • Privacy
  • Cookies
  • Terms
  • Delete account