Hypothesis Test Calculator

This hypothesis test calculator runs a one-tailed or two-tailed test for means, paired differences and proportions from summary numbers.

Checks on your data

  • Choose the hypotheses, α and the tail before looking at the data. A one-tailed test chosen after seeing the direction inflates false positives.
  • Statistical significance is not practical importance. Check the size of the effect as well as the p-value.

Results

Test used
Two-sample Welch t-test
Null hypothesis
H₀: μ₁ = μ₂
t statistic
1.99233
p-value
0.0506733
Decision
Fail to reject H₀ (p ≥ 0.05)
Critical value (±)
1.9984
Degrees of freedom
62.979
Observed effect (estimate − null)
4.3
Standard error
2.15827
95 % CI for the effect
-0.012993 to 8.613
two-sided interval for estimate − null
t distribution under H₀: shaded = p-value
-4-2024t = 1.992t
Show step-by-step solution
  1. Test: Two-sample Welch t-test. H₀: μ₁ = μ₂.
  2. Statistic = (estimate − null value) ÷ standard error = 4.3 ÷ 2.15827 = 1.99233, df = 62.979.
  3. Two-tailed p-value = 0.0506733.
  4. Compare p with α = 0.05: p ≥ α, so do not reject H₀.
StepsH₀, H₁, α, statistic, p
Reject ifp < α
Two-tailedH₁: ≠
One-tailedH₁: > or <

What Is Hypothesis Test?

A hypothesis test asks whether sample data give enough evidence to reject a null hypothesis. You state H₀ and H₁, choose a significance level α, compute a test statistic, find the p-value and reject H₀ if p < α.

Choose a one-sample t-test, a two-sample Welch t-test, a paired t-test, a one-proportion z-test or a two-proportion z-test, then enter the sample sizes, means, standard deviations or counts. Select a two-tailed, right-tailed or left-tailed alternative and the calculator returns the statistic, degrees of freedom, p-value, critical value, decision and a confidence interval for the effect, with the p-value shaded on the curve.

The article below explains each test, the formulas, a worked example and answers about two-tailed tests and what failing to reject means.

How to Use the Hypothesis Test Calculator

  1. Choose the test that matches your data.
  2. Enter the sample sizes, means, SDs or counts.
  3. Choose the alternative hypothesis and α.
  4. Read the statistic, p-value and decision.

Hypothesis Test Formula

One-sample t

t=xˉ−μ0s/nt=\frac{\bar x-\mu_0}{s/\sqrt n}

Welch two-sample t

t=xˉ1−xˉ2s12/n1+s22/n2t=\frac{\bar x_1-\bar x_2}{\sqrt{s_1^2/n_1+s_2^2/n_2}}

One-proportion z

z=p^−p0p0(1−p0)/nz=\frac{\hat p-p_0}{\sqrt{p_0(1-p_0)/n}}

Hypothesis Test Variables Explained

SymbolMeaningNotes
H₀, H₁Null and alternative hypotheses
αSignificance level
t or zTest statistic(estimate − null) ÷ SE
pp-value

Hypothesis Test Worked Example

Two groups: 30 people with mean 52.4 (SD 8.1) and 35 with mean 48.1 (SD 9.3). The standard error is √(8.1²/30 + 9.3²/35) = 2.158, so t = 4.3 ÷ 2.158 = 1.99 with about 63 degrees of freedom. The two-tailed p-value is about 0.051, just above α = 0.05, so you fail to reject H₀.

With the example values loaded in the calculator above, the steps are:

  1. Test: Two-sample Welch t-test. H₀: μ₁ = μ₂.
  2. Statistic = (estimate − null value) ÷ standard error = 4.3 ÷ 2.15827 = 1.99233, df = 62.979.
  3. Two-tailed p-value = 0.0506733.
  4. Compare p with α = 0.05: p ≥ α, so do not reject H₀.

Result: Test used = Two-sample Welch t-test; t statistic = 1.99233; p-value = 0.0506733; Decision = Fail to reject H₀ (p ≥ 0.05).

How to Read a Hypothesis Test

The test asks whether the data would be surprising if the null hypothesis were true. For two groups, 30 people with mean 52.4 (SD 8.1) and 35 with mean 48.1 (SD 9.3), the standard error is 2.158 and t = 4.3 ÷ 2.158 = 1.99.

With about 63 degrees of freedom, the two-tailed p-value is about 0.051. That is just above α = 0.05, so you fail to reject H₀. That is not proof of no difference. It says the data do not give enough evidence at that level, and the observed effect and its standard error show how large the gap could still be.

Where Hypothesis Test Is Used

One-sample tests

Compare a sample mean with a hypothesised value.

Two-sample tests

Compare two means, or two proportions.

Paired data

Test the mean of the differences.

Showing the steps

See the hypotheses, statistic, p-value and decision.

Common Hypothesis Test Mistakes to Avoid

  • State H₀ and H₁ before you look at the data.
  • Choose one-tailed or two-tailed from the research question, not from the result.
  • "Fail to reject" is not the same as "accept".
  • Report the effect size and an interval, not only the p-value.

Hypothesis Test Terms and Definitions

Null hypothesis
The default claim of no effect or no difference.
p-value
The probability of a result at least this extreme if H₀ is true.
α
The cut-off probability for rejecting H₀.

Hypothesis Test FAQs

How do I do a hypothesis test?

State H₀ and H₁, choose α, compute the test statistic and p-value from the data, then reject H₀ if p is less than α. The calculator performs and explains each step.

What is a two-tailed hypothesis test?

It tests for a difference in either direction. The p-value counts extreme results in both tails, so it is twice the one-tailed value for a symmetric statistic.

When do I use a z-test and when a t-test?

Use z when the population SD is known or the sample is very large. Use t when the SD is estimated from the sample, which is the usual case.

What does it mean to fail to reject H₀?

The data are not unusual enough, at your α, to rule out the null. It does not show that the null is true.

Related calculators

Last updated 2026-11-09. See our disclaimer.