Result
Enter parameters and click Calculate
Compute required sample size for surveys, A/B tests, and research studies.
No recently used tools
Loading categories...
Free online sample size calculator for surveys, A/B tests, and research studies. Compute required sample size with confidence level, margin of error, power analysis, finite population correction, step-by-step formulas, interactive Plotly chart, and Python export.
Compute required sample size for surveys, A/B tests, and research studies.
Sample size is the number of observations or respondents needed in a study to draw reliable conclusions about a population. Choosing the right sample size balances statistical rigor with practical constraints like cost and time.
Larger samples yield narrower confidence intervals and smaller margins of error, giving more precise estimates.
Adequate sample size ensures enough statistical power to detect real effects and avoid false negatives.
Too large wastes resources; too small produces unreliable results. Proper calculation finds the optimum.
| Factor | Effect on Sample Size | Explanation |
|---|---|---|
| Confidence Level | Higher → larger n | 99% confidence requires more data than 90% for the same precision |
| Margin of Error | Smaller → larger n | Halving the margin of error quadruples the required sample size |
| Variability | Higher → larger n | More variable populations need larger samples to estimate accurately |
| Power | Higher → larger n | 90% power needs about 30% more samples than 80% power |
| Effect Size | Smaller → larger n | Detecting small differences requires substantially more observations |
Statistical power (1 − β) is the probability that a study will detect a true effect when one exists. Under-powered studies waste resources because they are unlikely to produce significant results even when the effect is real.
Rule of thumb: Use 80% power as a minimum for most studies. Use 90% for confirmatory trials or when the cost of a false negative is high.
Use p=0.5 when unsure of the true proportion. Apply finite population correction when sampling >5% of the population. Account for expected non-response by inflating the sample size (e.g. divide by expected response rate).
Define the minimum detectable effect before starting. Smaller effects need much larger samples. Consider using sequential testing to stop early if the effect is large. Always run the test for the full planned duration.
Regulatory agencies typically require 80–90% power. Account for dropout rates by over-enrolling. Pre-register your sample size calculation. Use interim analyses with appropriate alpha-spending functions.