How to Determine the Right Sample Size
Sample size determination is one of the most critical steps in designing a survey, experiment, or research study. An insufficient sample size leads to results with wide confidence intervals and low statistical power, while an unnecessarily large sample wastes resources. This calculator helps you find the optimal balance.
The Core Formula
For estimating a population proportion (e.g., the percentage of customers who prefer a product), the required sample size for an infinite population is: n₀ = Z² × p(1−p) / E², where Z is the z-value corresponding to the desired confidence level, p is the expected proportion, and E is the margin of error. This formula is derived from the normal approximation to the binomial distribution.
Confidence Level and Z-Values
The confidence level represents how certain you want to be that the true population parameter falls within your margin of error. Common choices are 90% (Z = 1.645), 95% (Z = 1.96), and 99% (Z = 2.576). A higher confidence level requires a larger sample. The 95% confidence level is the most widely used standard in research.
Margin of Error
The margin of error (E) is the maximum acceptable difference between your sample estimate and the true population value. A ±5% margin of error means that if your survey finds 60% approval, the true value is likely between 55% and 65%. Halving the margin of error requires approximately quadrupling the sample size.
Population Proportion
If you have no prior estimate of the population proportion, use 50% (p = 0.5), which maximizes the product p(1−p) and gives the largest (most conservative) sample size. If prior research or pilot studies suggest the proportion is far from 50%, using that estimate will reduce the required sample.
Finite Population Correction (FPC)
When sampling from a small, finite population (e.g., all employees of a company), the standard formula overestimates the required sample size. The finite population correction adjusts for this: n = n₀ / (1 + (n₀ − 1)/N). This correction becomes significant when the sample is more than about 5% of the population.
Practical Considerations
Always increase your calculated sample size to account for expected non-response. If you anticipate a 30% response rate, divide the required sample by 0.30. Also consider stratification, clustering effects (design effect), and the specific statistical tests you plan to perform, as more complex analyses may require larger samples.