Confidence Interval Calculator
Compute confidence intervals for means — 95%, 99% or custom.
Confidence Interval Calculator
How was your experience with this tool?
Found a bug? Missing a feature? Tell us — it takes 10 seconds.
How to use Confidence Interval Calculator
Follow these steps — everything happens instantly in your browser.
- 1
Step 1. Enter the sample mean, standard deviation and sample size.
- 2
Step 2. Choose a confidence level (90%, 95%, 99% or custom).
- 3
Step 3. See the confidence interval and margin of error.
Confidence Interval Calculator: Margin of Error for Sample Means
What Is the Confidence Interval Calculator?
The EasyFileKit Confidence Interval Calculator takes a sample mean, standard deviation and sample size, then produces a confidence interval — a range of values that is likely to contain the true population mean at your chosen confidence level. It supports 90%, 95%, 99% and custom confidence levels, and uses the t-distribution when the population standard deviation is unknown (which is the typical case in practice). The margin of error is displayed alongside the interval bounds. All computation runs locally in your browser.
What Is a Confidence Interval?
A confidence interval gives you a range estimate rather than a single point estimate. If you survey 100 customers and find an average satisfaction score of 7.4, that single number does not tell you how precise your estimate is. A 95% confidence interval might be 7.1 to 7.7, meaning you can be 95% confident that the true population average falls within that range. The width of the interval reflects your uncertainty — narrower intervals mean more precision.
The confidence level (90%, 95% or 99%) tells you how often the method would capture the true mean if you repeated the sampling many times. A 95% confidence level means that in 95 out of 100 repeated samples, the interval would contain the true population mean. It does not mean there is a 95% probability that the true mean lies in this specific interval — the true mean is fixed, and the interval either contains it or it does not. This is a common misinterpretation worth understanding clearly.
The Formulas Behind the Calculator
When the population standard deviation is known, the calculator uses the z-distribution: CI = mean +/- z * (sigma / sqrt(n)), where z is the critical value from the standard normal distribution (1.645 for 90%, 1.96 for 95%, 2.576 for 99%). When the population standard deviation is unknown — which is almost always the case in practice — the calculator uses the t-distribution with n-1 degrees of freedom. The t-distribution has wider tails than the z-distribution, producing slightly wider intervals for small samples, which correctly accounts for the additional uncertainty.
The margin of error is the distance from the sample mean to either edge of the interval: MOE = critical value * (standard deviation / sqrt(n)). Notice that the margin of error shrinks as the sample size increases (dividing by the square root of n) and grows as the standard deviation increases (more spread in the data means less precision). This relationship is why larger samples produce tighter intervals.
How to Use the Calculator
Enter your sample mean (the average of your observed data) - Enter the sample standard deviation (the spread of your observed data) - Enter the sample size (number of observations) - Select a confidence level: 90%, 95%, 99% or enter a custom percentage - The calculator displays the confidence interval (lower bound to upper bound) and the margin of error
Callout: If your sample size is below 30, the t-distribution makes a meaningful difference. For samples of 30 or more, the t-distribution closely approximates the z-distribution.
Choosing a Confidence Level
| Confidence Level | Critical z | Critical t (df=29) | Use Case |
| --- | --- | --- | --- |
| 90% | 1.645 | 1.699 | Exploratory analysis, quick checks |
| 95% | 1.960 | 2.045 | Standard for most research and business |
| 99% | 2.576 | 2.756 | High-stakes decisions, medical research |
| 99.9% | 3.291 | 3.659 | Extremely conservative estimates |
What Happens with Small Samples
With small sample sizes (below 30), the t-distribution produces wider intervals than the z-distribution because there is more uncertainty about the true population standard deviation. As the sample size increases, the t-distribution converges toward the z-distribution. At n = 30 or more, the difference is negligible. This is why the 30-observation threshold is commonly cited as the boundary between small and large samples, although it is an approximation rather than a hard rule.
The practical implication is straightforward: if you have a small sample, your interval will be wider, reflecting greater uncertainty. To narrow the interval, you need either a larger sample or a lower confidence level. The calculator handles both distributions automatically based on your input, so you do not need to decide which one to use.
Interpreting the Results
The calculator returns three pieces of information: the lower bound, the upper bound and the margin of error. The interval [lower, upper] is the range within which the true population mean likely falls. The margin of error is the half-width of that interval. For example, a sample mean of 50 with a 95% confidence interval of 47.2 to 52.8 has a margin of error of 2.8. You would report this as: the mean is 50 (95% CI: 47.2 to 52.8, MOE = 2.8).
Practical Applications
Estimating the true average delivery time from a sample of recent shipments - Constructing a confidence interval for average customer spending from a survey sample - Determining the precision of a polling result before publishing election forecasts - Quality control: checking whether a manufacturing process mean falls within acceptable bounds - A/B testing: computing confidence intervals for the difference between two sample means
Frequently Asked Questions
Q: What is a confidence interval?
A: A range of values likely to contain the true population mean, given a specified confidence level. It provides both an estimate and a measure of its precision.
Q: What confidence level should I use?
A: 95% is the standard for most applications. Use 99% for high-stakes or medical decisions where you need greater certainty. Use 90% for exploratory analysis where a narrower interval is more useful than high confidence.
Q: What if I do not know the population standard deviation?
A: Enter the sample standard deviation. The calculator automatically uses the t-distribution instead of the z-distribution, which is the correct approach when the population standard deviation is unknown.
Related Tools
Z-Score Calculator — find how many standard deviations a value is from the mean - Pearson Correlation Calculator — measure the linear relationship between two variables - Variance & Standard Deviation Calculator — compute spread from your raw data - Linear Regression Calculator — fit a line to bivariate data - Tool page — open the Confidence Interval Calculator
Want the extended step-by-step tutorial? Read it here.
Why use this tool
Private by design
All processing happens locally in your browser. Open DevTools → Network and you'll see zero file uploads. Ever.
Instant
No upload wait, no queue, no server round-trip. Results appear the moment you drop a file.
Free & unlimited
No accounts, no watermarks, no daily caps. Use it as many times as you like, forever.
Works everywhere
Desktop, tablet or phone — every tool is responsive and installable as a PWA for offline use.
Frequently asked questions
Everything you might want to know about confidence interval calculator.
❤️ This tool is free — forever.
Sharing it helps more people discover it, and ad revenue from visitors is what keeps it free. No accounts, no catch.
Z-Score Calculator
z = (x − μ) / σ — with percentile and tail probability.
Pearson Correlation Calculator
Measure linear correlation between two variables — r from −1 to +1.
Variance & Standard Deviation Calculator
Compute variance and standard deviation — population & sample.
Linear Regression Calculator
Fit y = mx + b to (x, y) data points — with R² correlation.