Code tool

One-Sample t-Test Calculator

Enter your own sample summary statistics. Two-sided test; fixed α = 0.05. No raw data or external dataset is loaded.

In-browser processingNo account requiredPrivacy details ↗

Two-sided test; fixed α = 0.05. No raw data or external dataset is loaded.

Assumes independent observations and an approximately normal population, especially for small samples. t = (mean − hypothesized mean)/(s/√n); df = n − 1. The interval estimates the population mean.

Numerical scope: each sample size is limited to 1,000,000. Extreme scales or nonconvergence are rejected; a p value displayed as 0 can reflect floating-point underflow.

Method reference: NIST

A QUICK WALKTHROUGH

How to use this tool

  1. Enter your own sample summary statistics.
  2. Calculate the two-sided test at α = 0.05.
  3. Review t, degrees of freedom, p value and the 95% confidence interval.

Method and assumptions

Assumes independent observations and an approximately normal population, especially for small samples. t = (mean − hypothesized mean)/(s/√n); df = n − 1. The interval estimates the population mean.

Local calculation

Only the summary statistics you enter are used. Calculations run in your browser. Numerical scope: each sample size is limited to 1,000,000. Extreme scales or nonconvergence are rejected; a p value displayed as 0 can reflect floating-point underflow.

GOOD TO KNOW

Common questions

Does a nonsignificant result prove equal means?

No. Failing to reject the null hypothesis does not establish equivalence. Check the confidence interval and whether the sampling assumptions apply.