Sample Size Calculator

StatisticsLast updated: August 17, 2026

Sample size is the minimum number of participants or observations a study needs in order to represent its population. A badly chosen sample creates two basic risks: if it is too small, the findings cannot be generalized to the population and real effects go undetected; if it is needlessly large, time and resources are wasted and ethics committees may raise questions. In theses, journal articles, and grant applications, reviewers want to see which formula and which assumptions produced the sample size.

This calculator uses Cochran's (1977) formula, the most widely accepted approach in the literature for studies based on estimating a proportion (surveys, prevalence studies, opinion polls), and it applies the finite population correction automatically when a population size is entered. Based on the confidence level and the margin of error you choose, it returns the required minimum number of participants, a target with a 10% attrition allowance, a chart of how the requirement changes with the margin of error, and a ready-made table by population size.

%
±5% is the common choice; use ±3% when a precise estimate is required.
%
The estimated proportion of the characteristic in the population; if it is unknown, leave it at 50% (the safest value).
Enter N for limited populations such as a school, an institution, or a province; leave it empty for general population studies.

Required Sample Size in Common Survey Scenarios

The values below are computed from Cochran's formula assuming an infinite population and a 50% expected proportion; when a population size is entered, the finite population correction lowers these numbers.

90% confidence, ±5% margin of error
271 people
n₀ = 270.55; the lowest sample requirement among the common scenarios
95% confidence, ±5% margin of error
385 people
n₀ = 384.15. The standard scenario in the social sciences; the literature often cites it as 384 as well.
99% confidence, ±5% margin of error
664 people
n₀ = 663.49. Raising the confidence level from 95% to 99% increases the required sample by roughly 73%.
95% confidence, ±3% margin of error
1,068 people
n₀ = 1,067.07. Lowering the margin of error from ±5% to ±3% multiplies the sample by about 2.8.
Assumed expected proportion
50%
The product p · (1 − p) reaches its maximum (0.25) at p = 0.50; when the proportion is unknown it is the safest choice, because it yields the largest sample.
Recommended attrition allowance
+10%
Aiming for 10% more than the calculated number is common practice to absorb incomplete and careless responses; in the 95% and ±5% scenario that comes to 424 people.

Computed with Cochran's (1977) formula under the assumption of an infinite populationKaynak: Cochran, W. G. (1977) — Sampling Techniques (3rd edition)

Formula

n₀ = z² · p · (1 − p) / e²   (Cochran's formula)
Finite population correction: n = n₀ / ( 1 + (n₀ − 1) / N )
z: critical value for the confidence level (90% → 1.645; 95% → 1.960; 99% → 2.576)
p: expected proportion (0.50 if unknown), e: margin of error (e.g. 0.05)

This formula is for descriptive and survey research based on estimating a proportion; in experimental designs built on hypothesis tests such as a t-test, ANOVA, or regression, the sample size should be derived from a power analysis (with G*Power, for instance).

How to Calculate

  1. Choose the confidence level — 95% is the standard in the social sciences, while 99% may be preferred in medicine.
  2. Set the margin of error: ±5% is widely accepted; lower it to ±3% for studies that need a precise estimate.
  3. Enter the expected proportion — leave it at 50% if you have no estimate from a pilot study or the literature.
  4. If the population is limited (a school, an institution, a province), enter its size; leave it empty for a general population.
  5. Read the required minimum sample and the recommendation with a 10% attrition allowance; use the chart and the table to explore alternative scenarios.

Worked Examples

Standard survey scenario (95%, ±5%)

The most common scenario: 95% confidence, a ±5% margin of error, and a 50% expected proportion. Cochran's formula gives n₀ = 384.15; rounded up, 385 participants are required, and with a 10% attrition allowance 424 people are recommended.

Required minimum sample size: 385 · Infinite-population sample size (n₀): 384.15 · Finite population correction: Not applied — the population was assumed infinite

Survey in a school of 1,000

When the population is 1,000 people, the finite population correction comes into play: while n₀ = 384.15 for an infinite population, the required sample drops to 278; with a 10% attrition allowance, reaching 306 students should be the target.

Required minimum sample size: 278 · Infinite-population sample size (n₀): 384.15 · Finite population correction: Applied (N = 1,000)

High-precision estimate (99%, ±3%)

In a precise design such as a 99% confidence level with a ±3% margin of error, the required sample rises to 1,844 participants (n₀ = 1,843.03); as precision increases, the sample grows quickly.

Required minimum sample size: 1,844 · Infinite-population sample size (n₀): 1,843.03 · Finite population correction: Not applied — the population was assumed infinite

Frequently Asked Questions

Where does the sample size of 384 come from?
With a 95% confidence level, a ±5% margin of error, and a 50% expected proportion, Cochran's formula gives n₀ ≈ 384.15 (384.16 if z is rounded to 1.96), which is rounded up and reported as 385; the figure 384 is also common in practice. This value holds when the population is treated as infinite; for a small population the required sample is smaller.
I do not know the population size — what should I enter?
You can leave the population size field empty. The calculator then uses Cochran's n₀ formula under the assumption of an infinite population. If the population is above 10,000, the effect of the finite population correction is negligible in practice anyway.
Why is 50% recommended for the expected proportion?
The product p(1−p) reaches its maximum (0.25) at p = 0.50, which makes the formula return the largest, and therefore the safest, sample size. Unless you have a strong estimate of the true proportion from previous research, using 50% is the standard approach.
What happens if I cannot reach the computed sample size?
As the sample shrinks, the margin of error grows and the findings generalize less well to the population. In that case you must state clearly in the limitations section that you have accepted either a lower confidence level (90%, say) or a wider margin of error (±7%, say).
Which sampling methods is this calculator valid for?
The formula assumes simple random sampling. With stratified sampling the computation should be done per stratum, and with cluster sampling the result must be multiplied by the design effect (deff). For complex sampling designs, expert support is recommended.
What is the difference between this calculator and G*Power?
This calculator uses Cochran's formula for descriptive research and surveys based on estimating a proportion. G*Power computes a sample size from the power of a specific statistical test (t-test, ANOVA, regression). For experimental designs built on hypothesis testing, a power analysis should be preferred.