Central Limit Theorem Calculator & Simulator

Interactive CLT simulator — pick a Uniform, Skewed or Bimodal population, draw thousands of samples of any size n, and watch the sampling distribution of the mean turn into a bell curve regardless of the population's shape.

Population shape

Heavily right-skewed. Most values are small; a long thin tail stretches to the right. This is the hardest shape for the CLT.

Mean of sample means (empirical)
2.992
Theory: μ = 3.000
SD of sample means (empirical)
0.551
Theory: σ/√n = 3.000 / √30 = 0.548
Population vs. sampling distribution
Raw population — Skewed (Exponential)
5,000 draws, Exponential (rate λ = 1/3)
μ=3.000.05.010.015.020.0count
Sample means — n = 30, 2,000 samples
Should approach Normal(μ = 3.00, SE = 0.548)
X̄̄=2.990.81.93.04.15.2count

The left histogram shows the population you're sampling from — for the Skewed and Bimodal choices it is visibly non-normal. The right histogram shows the distribution of sample means. Even for those non-normal populations, the right histogram is centred at μ and takes on a bell shape — that is the Central Limit Theorem. Move the n slider up to make it narrower and more normal; slide it down to n = 2 or n = 3 to watch it break.

What is the Central Limit Theorem?

The Central Limit Theorem (CLT) says that if you take repeated random samples of size n from any population with a finite mean μ and standard deviation σ, the distribution of the sample means approaches a normal distribution as n grows — with mean μ and standard deviation σ / √n (called the standard error). The astonishing part is the phrase "any population." The original data can be uniform, heavily skewed, bimodal, or anything else with a finite mean and variance — the distribution of sample means still becomes bell-shaped.

That is exactly what the simulator above shows. The left histogram is a big sample of raw population values — clearly not normal for the Skewed or Bimodal choices. The right histogram is the distribution of 2,000 sample means (each averaging 30 draws). Notice how it centres on μ and takes on a bell shape even though the raw population histogram on the left doesn't. That is the CLT.

The CLT explained, piece by piece

Central Limit Theorem Calculator (CLT)

Draw independent samples of size n from any population with a finite mean μ and finite standard deviation σ. As n grows, the distribution of the sample mean X̄ becomes approximately Normal — no matter what shape the original population has. That is the whole content of the CLT.

X̄ ≈ Normal(μ, σ / √n) for large n
sample mean of one sample of size n·μpopulation mean·σpopulation standard deviation·nsample size (per sample)
populationsample meansany shape → Normal(μ, σ/√n)
Example
Given
Exponential population, μ = 3, σ
= 3
samples of n = 30
Substitute
sampling distribution ≈ Normal(3, 3/√30)
Answer
≈ Normal(3, 0.548)

Standard error of the mean

The standard deviation of the sampling distribution has its own name: the standard error. It shrinks by a factor of √n as sample size grows, so to halve the standard error you need four times as much data — not twice as much.

SE = σ / √n
SEstandard deviation of the sample mean X̄·σpopulation standard deviation·nsample size
n=4n=16n=64SE = σ/√n — bigger n, tighter spread
Example
Given
σ = 3
n = 30
Substitute
SE = 3 / √30
= 3 / 5.477
Answer
SE ≈ 0.548

How sample size affects the bell shape

Two things happen at once as n increases: the sampling distribution narrows (because SE = σ/√n shrinks) and it becomes visibly more bell-shaped, losing the fingerprints of the population's original skew or bimodality.

bigger n → narrower spread AND more Normal shape
n smallsampling distribution still carries the population's shape·n largesampling distribution ≈ Normal, regardless of source
μn large → tight bell around μ
Example
Given
σ = 3
compare n = 4 vs n
= 64
Substitute
SE(4) = 3/2
= 1.50
SE(64) = 3/8
= 0.375
Answer
four times the n → half the SE

The n ≥ 30 rule of thumb

Textbooks quote n ≥ 30 as a rough guideline for when the CLT is 'good enough' to treat X̄ as Normal. Symmetric populations need much less (n = 10 often works). Heavily skewed populations may need n = 50 or more before the sampling distribution looks convincingly bell-shaped.

n ≥ 30 is a guideline
not a hard cutoff
symmetricsmall n is usually enough·skewed / bimodalneeds a larger n before X̄ looks Normal
μapproach to Normal depends on skew
Example
Given
Uniform population
n = 12
Substitute
already looks approximately Normal
Answer
rule-of-thumb met

Why does the Central Limit Theorem matter?

Almost every classical inference procedure you learn in a first stats course — confidence intervals for the mean, one-sample z-tests, t-tests, ANOVA, regression — leans on the assumption that the sample mean (or something like it) is approximately normally distributed. In real data the underlying population rarely is. The CLT is what lets those methods work anyway: as long as n is reasonably large, the SAMPLE MEAN behaves like it came from a normal distribution even when the raw data does not.

This is why textbooks recite the rule of thumb n ≥ 30. Treat it as a rough guideline, not a strict cutoff. For a roughly symmetric population, n = 10 or n = 15 is often more than enough. For a heavily skewed population like the Exponential option in the simulator, n = 30 is only a mediocre approximation and you may want n = 50 or n = 100 to be comfortable. The simulator lets you check for yourself instead of trusting the rule of thumb.

How sample size affects the sampling distribution

Move the sample size (n) slider and watch two things happen at once in the right-hand histogram:

  • It gets narrower. The standard error is σ/√n, so doubling n only shrinks the spread by a factor of √2 ≈ 1.41 — that is why halving the standard error requires four times as much data, not twice as much.
  • It looks more normal. At n = 2 or n = 3 the sampling distribution still carries fingerprints of the population's shape — a right skew for the Exponential, a soft double peak for the Bimodal. By n ≈ 30 the shape is close to bell-shaped; by n ≈ 100 it is visually indistinguishable from a normal curve.

The number of samples slider does something different — it does NOT invoke the CLT, it only sharpens the picture of the sampling distribution. Even a million samples of size n = 2 won't make the sampling distribution of the mean look normal for a skewed population. The variable that matters for the CLT is n.

Common mistakes

  • "The CLT says my data becomes normal." No. The population's shape does not change no matter how much data you collect. The CLT is a statement about the distribution of sample MEANS, not raw data.
  • Treating n ≥ 30 as a hard rule. It is a rough guideline. Heavily skewed populations may need much larger n; roughly symmetric ones need much less.
  • Confusing "number of samples" with "sample size". Drawing more samples of a tiny size does not invoke the CLT — it only gives you a sharper picture of a sampling distribution that hasn't yet converged.
  • Assuming the CLT applies to any statistic. The classical CLT is about the sample mean. Sample maxima, minima, ranges, and other statistics have their own (often non-normal) limit distributions.
  • Ignoring finite variance. The CLT needs a finite population variance σ². Heavy-tailed distributions like a Cauchy distribution have infinite variance and the CLT does not apply — no matter how large n is, the sample mean does not converge to a normal.

Features of this calculator

  • Three population shapes (Uniform, Skewed / Exponential, Bimodal) chosen specifically to be visibly non-normal.
  • Side-by-side histograms — raw population on the left, sample means on the right — so the CLT effect is obvious at a glance.
  • Sample-size slider from n = 2 up to n = 200 with instant re-simulation so you can watch the sampling distribution narrow and become bell-shaped as n grows.
  • Draw up to 5,000 samples in a single click — enough to give a smooth histogram of sample means without freezing the page.
  • Empirical mean and SD of the sample means displayed alongside the theoretical values (μ and σ/√n) so you can verify the CLT numerically as well as visually.
  • Re-run button reseeds the RNG so you can see how much the sample-means histogram wobbles from run to run — another intuition many stats textbooks skip.
  • Show/hide step-by-step working that walks through the theorem, plugs in your population's μ and σ, computes σ/√n and compares it to the empirical SD from your simulation.
  • Fast enough for 1,000+ draws without freezing the page — the entire loop is pure numeric JavaScript, no charting library overhead.

Frequently asked questions

+What does the Central Limit Theorem actually say?

Draw repeated independent samples of size n from any population with finite mean μ and standard deviation σ. As n grows, the distribution of the sample means approaches Normal(μ, σ/√n), regardless of the population's shape.

+Does the CLT mean my raw data is normally distributed?

No. The population's shape does not change. What becomes normal is the distribution of the sample MEAN if you repeated the study many times.

+Is n ≥ 30 a hard rule?

No. It's a rough guideline. Symmetric populations need much smaller n; heavily skewed populations need larger n. The simulator lets you find a value of n that "looks bell enough" for your case.

+What is the standard error?

The standard deviation of the sampling distribution of the mean: SE = σ/√n. It shrinks as n grows and is what confidence intervals for the mean are built from.

+How is this different from a plain calculator?

Most CLT pages give you a number. This one is a simulator: it actually draws the samples and shows you the sampling distribution taking shape, which is the point of the theorem.

+How does 'Re-run' change anything?

It reseeds the random-number generator so you can see how much a fresh set of samples wobbles around the theoretical curve. It's a quick way to see that the empirical picture is a noisy estimate of the theoretical one.

Related calculators