The distinction between a t-test and paired t-test hinges on one question: are the two sets of measurements tied to the same subjects, or do they come from entirely different people? Choose a paired t-test when each observation in condition A is matched one-to-one with an observation in condition B — the same person measured before and after a treatment, for example. Choose an independent t-test (also called a two-sample t-test) when the two groups consist of different, unrelated individuals.
Choosing the wrong test is not just a technicality. The paired design removes between-subject variability by working with differences, making it considerably more powerful when the pairing is real. Apply the paired formula to independent data and you inflate degrees of freedom artificially; apply the independent formula to naturally paired data and you discard the statistical power you already had. This article covers the full t test and paired t test contrast: how to identify which applies, the formula for each, a fully worked numeric example of each, and the mistakes that most often trip up students and applied researchers.
The Core Distinction
The defining factor is not the research question — it is the structure of the data. Ask yourself whether each score in Group 1 has a natural partner in Group 2.
Paired data — examples:
- Blood pressure measured in the same patient before and after a drug
- Reaction time tested in the same driver sober and after one drink
- Reading scores for 30 students at the start and end of a semester
- Two products rated by the same consumer panel
- Twins assigned to different diet conditions (matched pairs)
Independent data — examples:
- Cholesterol in a treatment group vs. a placebo group (different patients in each group)
- Test scores of students taught by method A vs. students taught by method B (different students)
- Heights of adult men vs. heights of adult women
- Crop yield on fertilised plots vs. unfertilised plots (different plots)
The paired design reduces to a one-sample t-test applied to the differences. The independent design compares two separate sample means. Both belong to the t-test family and share the same t-distribution, but the formulas, the degrees of freedom, and the power characteristics differ meaningfully.
When to Use a Paired T-Test
Use the paired t-test when your study has one of the following structures:
- Repeated measures. You record the same variable from the same subject twice — once before an intervention and once after, or under two different experimental conditions (e.g., with and without caffeine).
- Matched pairs. Subjects are deliberately matched on a confounding variable before the study begins. Classical examples include twin studies and experiments that match participants on age, sex, or a pre-test score.
- Crossover design. Each participant receives both treatments, separated by a washout period. The order is typically counterbalanced across subjects.
The paired test is almost always more powerful than the independent test when pairing is meaningful, because it subtracts individual baseline differences that would otherwise inflate the error term. A patient whose blood pressure is naturally elevated will score high under both conditions; the paired test sees only the within-subject change, while the independent test treats all of that between-patient variation as noise.
When to Use an Independent T-Test
Use the independent t-test when:
- Two separate groups. Subjects are randomly assigned to one condition only — either the treatment or the control — with no matching between groups.
- Naturally distinct populations. You compare two groups that exist independently of each other: men vs. women, two classrooms, two cities.
- No logical pairing exists. There is no meaningful one-to-one correspondence between an observation in Group 1 and any specific observation in Group 2.
The independent t-test assumes that observations within each group are independent of each other, and that the two groups are independent of each other. It is the more commonly encountered form in randomised controlled trials and many social-science experiments.
The Paired T-Test: Formula
The paired t-test collapses the two-column problem into a single column of differences. For each pair i, compute:
dᵢ = x₁ᵢ − x₂ᵢ
where x₁ᵢ is the first measurement and x₂ᵢ is the second measurement for subject i. From the n differences, calculate the mean difference and the standard deviation of the differences:
d̄ = (Σ dᵢ) / n
sd = √( Σ(dᵢ − d̄)² / (n − 1) )
The t-statistic is:
t = d̄ / (sd / √n)
The null hypothesis is H₀: μd = 0 — the true mean difference is zero. The t-statistic follows a t-distribution with df = n − 1 degrees of freedom, where n is the number of pairs (not the total number of raw observations, which is 2n).
Because sd is computed on the differences rather than on the raw scores, individual variation common to both conditions cancels out. That is why the paired test is more sensitive when the pairing is genuine.
Example of a Paired T-Test
Scenario. Eight patients enrolled in an 8-week diet and exercise programme. Their systolic blood pressure (mmHg) was recorded before the programme and again at completion. Test at α = 0.05 whether the programme produced a significant reduction in blood pressure.
The Data
| Patient | Before | After | Difference (d = Before − After) |
|---|---|---|---|
| 1 | 135 | 128 | 7 |
| 2 | 140 | 133 | 7 |
| 3 | 128 | 122 | 6 |
| 4 | 150 | 141 | 9 |
| 5 | 132 | 127 | 5 |
| 6 | 145 | 138 | 7 |
| 7 | 138 | 134 | 4 |
| 8 | 142 | 136 | 6 |
Step 1 — Mean Difference
d̄ = (7 + 7 + 6 + 9 + 5 + 7 + 4 + 6) / 8 = 51 / 8 = 6.375 mmHg
Step 2 — Standard Deviation of the Differences
| dᵢ | dᵢ − d̄ | (dᵢ − d̄)² |
|---|---|---|
| 7 | 0.625 | 0.3906 |
| 7 | 0.625 | 0.3906 |
| 6 | −0.375 | 0.1406 |
| 9 | 2.625 | 6.8906 |
| 5 | −1.375 | 1.8906 |
| 7 | 0.625 | 0.3906 |
| 4 | −2.375 | 5.6406 |
| 6 | −0.375 | 0.1406 |
| Sum | 15.875 |
sd² = 15.875 / (8 − 1) = 15.875 / 7 ≈ 2.268
sd = √2.268 ≈ 1.506
Step 3 — T-Statistic
t = d̄ / (sd / √n)
= 6.375 / (1.506 / √8)
= 6.375 / (1.506 / 2.828)
= 6.375 / 0.532
≈ 11.98
Step 4 — Decision
Degrees of freedom: df = n − 1 = 7. At α = 0.05 (two-tailed), the critical t-value with 7 df is approximately 2.365. Because 11.98 ≫ 2.365, reject the null hypothesis. The programme produced a statistically significant reduction in systolic blood pressure (mean decrease = 6.375 mmHg, t(7) = 11.98, p < 0.001).
The high t-statistic reflects the consistency of the effect: every patient improved, so the differences clustered tightly around 6.375 with low variance.
The Independent T-Test: Formula
The independent t-test compares the means of two separate groups. Let x̄₁ and x̄₂ be the sample means, s₁ and s₂ the sample standard deviations, and n₁ and n₂ the sample sizes.
When the population variances can be assumed equal, first pool the two sample variances:
sp² = ( (n₁ − 1)s₁² + (n₂ − 1)s₂² ) / (n₁ + n₂ − 2)
sp = √sp²
Then:
t = (x̄₁ − x̄₂) / ( sp × √(1/n₁ + 1/n₂) )
Degrees of freedom: df = n₁ + n₂ − 2.
When variances cannot be assumed equal, use Welch’s t-test. The standard error changes to:
SE = √( s₁²/n₁ + s₂²/n₂ )
t = (x̄₁ − x̄₂) / SE
and the degrees of freedom are estimated via the Welch–Satterthwaite equation, which typically produces a non-integer. Welch’s t-test is the safer default when you are unsure about variance equality.
The NIST/SEMATECH e-Handbook of Statistical Methods, section 7.3.1 — Comparing the Means of Two Processes provides a complete derivation and decision procedure for both the equal-variance and unequal-variance forms.
Example of an Independent T-Test
Scenario. A school tests two teaching methods on 20 students randomly split into two equal groups. Group A (n = 10) uses an interactive project-based approach; Group B (n = 10) uses a traditional lecture approach. Test at α = 0.05 whether the methods produce different end-of-unit scores.
The Data
| Group A (interactive) | Group B (lecture) |
|---|---|
| 72 | 65 |
| 78 | 70 |
| 65 | 62 |
| 82 | 68 |
| 75 | 72 |
| 68 | 63 |
| 80 | 71 |
| 74 | 67 |
| 71 | 69 |
| 77 | 66 |
Step 1 — Group Means
x̄₁ = (72 + 78 + 65 + 82 + 75 + 68 + 80 + 74 + 71 + 77) / 10 = 742 / 10 = 74.2
x̄₂ = (65 + 70 + 62 + 68 + 72 + 63 + 71 + 67 + 69 + 66) / 10 = 673 / 10 = 67.3
Step 2 — Group Standard Deviations
For Group A (deviations from x̄₁ = 74.2, then squared and summed):
Σ(xᵢ − 74.2)² = (−2.2)² + 3.8² + (−9.2)² + 7.8² + 0.8²
+ (−6.2)² + 5.8² + (−0.2)² + (−3.2)² + 2.8²
= 4.84 + 14.44 + 84.64 + 60.84 + 0.64
+ 38.44 + 33.64 + 0.04 + 10.24 + 7.84
= 255.60
s₁² = 255.60 / 9 ≈ 28.40 s₁ ≈ 5.33
For Group B (deviations from x̄₂ = 67.3, then squared and summed):
Σ(xᵢ − 67.3)² = (−2.3)² + 2.7² + (−5.3)² + 0.7² + 4.7²
+ (−4.3)² + 3.7² + (−0.3)² + 1.7² + (−1.3)²
= 5.29 + 7.29 + 28.09 + 0.49 + 22.09
+ 18.49 + 13.69 + 0.09 + 2.89 + 1.69
= 100.10
s₂² = 100.10 / 9 ≈ 11.12 s₂ ≈ 3.33
Step 3 — Pooled Variance
df = n₁ + n₂ − 2 = 10 + 10 − 2 = 18.
sp² = ( (10 − 1) × 28.40 + (10 − 1) × 11.12 ) / 18
= ( 255.60 + 100.10 ) / 18
= 355.70 / 18
≈ 19.76
sp = √19.76 ≈ 4.44
Step 4 — T-Statistic
t = (74.2 − 67.3) / ( 4.44 × √(1/10 + 1/10) )
= 6.9 / ( 4.44 × √0.20 )
= 6.9 / ( 4.44 × 0.4472 )
= 6.9 / 1.986
≈ 3.47
Step 5 — Decision
df = 18. At α = 0.05 (two-tailed), the critical t-value is approximately 2.101. Because 3.47 > 2.101, reject the null hypothesis. The interactive method produced significantly higher scores than the lecture method (mean difference = 6.9 points, t(18) = 3.47, p < 0.01).
Try It with the T-Test Calculator
For the paired t-test, you can adapt a one-sample t-test calculator. Enter d̄ as the “sample mean,” zero as the “hypothesized mean” (because H₀: μd = 0), sd as the “sample standard deviation,” and n (the number of pairs) as the sample size.
Using the blood pressure example above: sample mean = 6.375, hypothesized mean = 0, sample SD = 1.506, n = 8:
For a full-page tool, open the t-test calculator. All statistical tools are listed on the calculators hub.
Degrees of Freedom and What They Mean
One practical consequence of the design choice is a different df count — and df determines the critical t-value from the table.
Paired t-test: df = n − 1, where n is the number of pairs. With 8 pairs, df = 7. Although you recorded 16 raw measurements, reducing them to 8 differences leaves only 8 independent values, then one degree of freedom is consumed to estimate d̄.
Independent t-test (equal variances): df = n₁ + n₂ − 2. With two groups of 10, df = 18. One degree of freedom is used to estimate x̄₁ and another to estimate x̄₂.
Fewer degrees of freedom push the critical t-value higher, making significance harder to achieve. But the paired design typically compensates by producing a much larger t-statistic, because individual variability is removed from the error term. Compare the two examples: t = 11.98 at df = 7 is far more significant than t = 3.47 at df = 18, even though the paired test has the smaller df.
What the Two Tests Share
Despite their structural differences, both tests rest on the same core assumptions:
- Approximately normal distributions. The paired test requires that the differences be approximately normal; the independent test requires that scores within each group be approximately normal. Both are robust to moderate violations when n ≥ 30, thanks to the central limit theorem.
- Interval or ratio scale. Neither test is valid on ordinal or nominal data. If scores are ranks, use the non-parametric equivalents (Wilcoxon signed-rank for paired, Mann-Whitney U for independent).
- Independence within groups. In the paired test, each difference dᵢ must be independent of the others. In the independent test, observations within each group must be independent. Neither test handles clustering (e.g., students nested in classrooms) without additional adjustment.
- H₀ of no difference. Both default to a null hypothesis that the effect is zero.
The NIST/SEMATECH e-Handbook of Statistical Methods, section 7.4.1 — Paired Comparisons gives a formal treatment of the paired design’s assumptions and its relationship to the one-sample t-test, alongside guidance on when to prefer the paired approach.
Common Mistakes
Applying the Independent Test to Paired Data
If you ignore a natural pairing and run a two-sample t-test, you treat each measurement as unrelated to its partner. Between-subject variability — the fact that one patient’s blood pressure is naturally higher than another’s — re-enters the error term and inflates the standard error. In the blood pressure example, treating the 16 raw values as two independent groups of 8 would produce a much smaller t-statistic and potentially a non-significant result, even though the treatment effect is genuine and large.
Applying the Paired Test to Independent Data
Artificially pairing two unrelated groups creates meaningless differences. “Subject 1 in Group A” and “subject 1 in Group B” have nothing in common when the assignment was random and the subjects are different people. The paired formula would incorrectly halve the degrees of freedom (from n₁ + n₂ − 2 to n − 1), inflating the apparent precision of the estimate without any real justification.
Assuming Equal Group Sizes Means Paired
Having the same n in both groups does not create pairing. Two groups of 30 unrelated students are not paired just because n₁ = n₂ = 30. Pairing requires a specific logical link between each member of Group 1 and exactly one member of Group 2 — whether biological (twins), temporal (the same person at two time points), or deliberate (matched on a covariate).
Inconsistent Difference Direction
In a paired t-test, define dᵢ = x₁ᵢ − x₂ᵢ uniformly across all pairs. If you accidentally compute some differences as Before − After and others as After − Before, the sum Σdᵢ will be artificially small (some positive values cancelling negative ones), producing a biased d̄ and an incorrect t-statistic. Always subtract in the same direction and verify the sign of d̄ matches the expected direction of the effect.
Violating the Independence-Within-Pairs Assumption
In a crossover study, if the treatment from period 1 still affects outcomes in period 2 — a carryover effect — the differences dᵢ are not independent of each other. Use a long enough washout period to eliminate carryover, or consider a mixed-effects model that explicitly accounts for the period effect.
Frequently Asked Questions
What is the difference between a t-test and paired t-test?
A “t-test” is a family name covering several related tests. The paired t-test specifically requires that each observation in one group is matched to one observation in the other — most commonly, the same subject measured twice. The standard two-sample independent t-test assumes the two groups are unrelated. The paired version computes differences within each pair and then tests whether the mean of those differences is zero, which eliminates between-subject variance and often yields a much larger t-statistic.
How do I decide between paired and independent?
Ask: does each observation in Group 1 have a designated partner in Group 2? If the same person appears in both groups, or subjects were deliberately matched before the study, use the paired t-test. If the two groups contain different, unrelated individuals, use the independent t-test.
Can I use a paired t-test if the groups are different sizes?
No. The paired test requires exactly n matched pairs — Group 1 and Group 2 must each contribute exactly one observation to every pair. If the groups have different sizes, you cannot form complete pairs for all observations, and the independent t-test (or, if some pairs exist, a paired test on only the paired subset with the remainder dropped) is the correct approach.
Which is more powerful, paired or independent?
The paired test is more powerful when the correlation between the two measurements within a pair is positive and substantial (roughly ρ > 0.5). Higher correlation means more between-subject variance is removed, giving a smaller denominator in the t-formula and a larger t. The trade-off is fewer degrees of freedom (n − 1 vs. n₁ + n₂ − 2), which raises the critical value slightly, but in practice the variance reduction wins out when the pairing is real.
Does the independent t-test require equal sample sizes?
No. The pooled-variance independent t-test works for any combination of n₁ and n₂; unequal sizes just produce a differently weighted pooled variance. If you also suspect unequal variances between the groups, use Welch’s t-test, which does not assume equal variances and adjusts the degrees of freedom accordingly.
What non-parametric alternatives exist?
For small samples or clearly non-normal data: replace the paired t-test with the Wilcoxon signed-rank test (tests whether the median difference is zero), and replace the independent t-test with the Mann-Whitney U test (tests whether one distribution tends to produce larger values than the other). Both make fewer distributional assumptions but are somewhat less powerful when normality holds.
What hypotheses does each test evaluate?
Paired t-test:
- H₀: μd = 0 (the mean difference is zero — no effect)
- H₁: μd ≠ 0 (two-tailed), or μd > 0 or μd < 0 (one-tailed, when you predict the direction)
Independent t-test:
- H₀: μ₁ = μ₂ (the two group population means are equal)
- H₁: μ₁ ≠ μ₂ (two-tailed), or μ₁ > μ₂ or μ₁ < μ₂ (one-tailed)
How do I use the paired t-test with a one-sample calculator?
Enter d̄ (mean of your differences) as the sample mean, 0 as the hypothesized mean (because H₀ is μd = 0), sd (standard deviation of your differences) as the sample SD, and n (the number of pairs) as the sample size. The calculator returns the t-statistic, degrees of freedom (n − 1), and the two-tailed p-value. Compare the p-value to your chosen α level (typically 0.05) to make your decision.
Summary
The paired t-test and the independent t-test both use the t-distribution to assess whether a difference is large enough relative to chance. The right choice depends entirely on data structure, not on the research question:
- Paired design → same subjects measured twice, or deliberately matched pairs → compute dᵢ for each pair → test whether d̄ differs from zero → df = n − 1
- Independent design → two separate groups of unrelated subjects → compare x̄₁ and x̄₂ directly → pool variances → df = n₁ + n₂ − 2
Using the paired formula on independent data wastes information and can produce misleading results; using the independent formula on paired data throws away real statistical power. Identify the structure first, then apply the matching test. The example of a paired t-test above (blood pressure, t ≈ 11.98) and the example of an independent t-test (teaching methods, t ≈ 3.47) show how different the t-statistics can be even for effects of comparable real-world magnitude, once the correct error term is used.