Sample size is not chosen by habit. It follows from the study question, design, outcome, desired precision or power, population structure, and expected data loss.
What determines sample size?
For a cross-sectional survey estimating a proportion, the main inputs are confidence level, margin of error, and expected proportion. A 95% confidence level commonly uses a Z value of 1.96. A smaller margin of error requires a larger sample. When the expected proportion is unknown, 50% is conservative because it produces the largest variance.
n = Z² × p(1 − p) / e²Here, n is the initial sample size, Z is the confidence coefficient, p is the expected proportion, and e is the absolute margin of error.
Worked example
A vaccination survey expects 70% coverage, uses 95% confidence, and accepts a margin of error of 5 percentage points.
n = 1.96² × 0.70 × 0.30 / 0.05² = 322.7
Round up to 323 participants before applying design effect or non-response adjustments.
Important adjustments
Finite population correction
When sampling a substantial share of a small population, adjust the initial estimate:
n adjusted = n / [1 + (n − 1) / N]Cluster sampling
Multiply by a design effect when observations within clusters are correlated. The value should come from prior surveys or a justified planning assumption.
Non-response
Divide by the expected response proportion. If 10% non-response is expected, divide the required completed sample by 0.90 rather than simply adding 10%.
How to report the calculation
State the primary outcome, formula or software, expected proportion, confidence level, precision, population size if used, design effect, anticipated non-response, and final rounded sample. This allows reviewers to reproduce the calculation.
Common questions
Does a larger population always require a larger sample?
Not once the population is large relative to the sample. Precision depends more strongly on variability and margin of error.
Should every outcome have its own calculation?
Calculate requirements for important primary outcomes and use the largest defensible sample.
Is this formula suitable for comparing two groups?
No. Comparisons of means, risks, or proportions require effect size, power, allocation ratio, and group-specific assumptions.
References
Lwanga SK, Lemeshow S. Sample Size Determination in Health Studies. World Health Organization; 1991.
Cochran WG. Sampling Techniques. 3rd ed. Wiley; 1977.