T-Statistic Calculator
Enter your sample mean, a hypothesized population mean, the sample standard deviation, and the sample size to get the one-sample t-statistic and see how far your data sits from the value you are testing.
One-sample t-test in one step
Enter four numbers — the sample mean, the hypothesized mean, the sample standard deviation, and the sample size — and the calculator returns the t-statistic t = (x̄ − μ) / (s / √n).
Use the sample SD
Supply the sample standard deviation (computed with n − 1) and a sample size of at least 2, since the standard error divides s by the square root of n.
What is a t-statistic?
Standard errors away from the mean
The t-statistic calculator answers a single question: how many standard errors does your sample mean sit away from the value you are testing against? It is the test statistic of the one-sample t-test, the standard tool for checking whether a sample average differs meaningfully from a hypothesized population mean when you only have an estimate of the spread. From four inputs — the sample mean (x̄), the hypothesized mean (μ), the sample standard deviation (s), and the sample size (n) — it returns a single dimensionless number you can compare against a t-distribution to judge significance.
Enter your sample mean, the hypothesized mean, the sample standard deviation, and the sample size to get the one-sample t-statistic instantly.
The t-statistic is the gap between the sample mean and the hypothesized mean, divided by the standard error of the mean (the standard deviation divided by the square root of the sample size).
t = (x̄ − μ) / (s / √n)The numerator measures the raw difference between what you observed and what you assumed. The denominator, the standard error, shrinks as the sample grows, so the same difference becomes more convincing with more data. Dividing one by the other turns the gap into a count of standard errors, which is exactly what you compare to a critical value.
Suppose you measure a sample of 25 with a mean of 52, while the published population mean is 50 and your sample standard deviation is 5.
Find the standard error
s / √n = 5 / √25 = 5 / 5 = 1 — the standard error of the mean.
Take the difference
x̄ − μ = 52 − 50 = 2 — how far the sample mean is from the hypothesized mean.
Divide
2 / 1 = 2 — the t-statistic. The sample mean sits 2 standard errors above 50, with 25 − 1 = 24 degrees of freedom.
The t-statistic tells you how far the sample mean lies from the hypothesized mean, measured in standard-error units rather than raw units. A t of 2 means the sample mean is two standard errors above the tested value; a negative t means it falls below it. The sign carries the direction and the magnitude carries the strength of the evidence — values near zero say the sample is consistent with the hypothesized mean, while larger magnitudes point to a real difference. To decide significance, compare the absolute value to a critical value from a t-table at your chosen significance level and your degrees of freedom (n − 1). For 24 degrees of freedom and a two-tailed test at the 5% level, the critical value is about 2.06, so a t of 2 falls just short of significance — close, but not quite enough to reject the null hypothesis. Because the t-distribution depends on the sample size through its degrees of freedom, the same t-statistic can be significant in a large sample and not in a small one.
The formula is exact, but the test behind it rests on a few assumptions worth keeping in mind.
One-sample test on roughly normal data
This calculator computes the one-sample t-statistic, which compares a single sample mean against a fixed hypothesized value — it is not the two-sample or paired t-test. The t-test assumes the underlying data are roughly normally distributed (the assumption matters most for small samples) and that the observations are independent. Use the sample standard deviation, computed with n − 1, and remember that the degrees of freedom are n − 1 when you look up a critical value or p-value. The calculator returns no result when the standard deviation is not positive or the sample size is below 2.