t-Test Calculator

Calculate the t-statistic and p-value for hypothesis testing.

This tool is for informational and educational purposes only. It is not a substitute for professional financial, medical, legal, or engineering advice. See Terms of Service.

Can't find what you need?

Request a Tool

How to Use the t-Test Calculator

Select one-sample or two-sample test. For one-sample, enter your sample mean, hypothesized mean, standard deviation, and sample size. For two-sample, enter the mean, standard deviation, and size for each group. The calculator computes the t-statistic, degrees of freedom, and two-tailed p-value.

About This Calculator

The t-test determines whether there is a significant difference between means. The one-sample test compares a sample mean to a known or hypothesized value. The two-sample (independent) test compares two group means. It uses the t-distribution, which accounts for uncertainty when the population standard deviation is unknown.

Frequently Asked Questions

When should I use a t-test vs a z-test?

Use a t-test when the population standard deviation is unknown and you estimate it from the sample. Use a z-test when you know the population standard deviation or have very large samples (n > 30).

What is Welch's t-test?

This calculator uses Welch's approximation for two-sample tests, which does not assume equal variances. It adjusts the degrees of freedom based on the sample sizes and variances.

What if my data is not normally distributed?

The t-test is robust to moderate departures from normality, especially with larger samples. For small samples from non-normal distributions, consider the Mann-Whitney U test.