Statistics

T-Test Calculator: Independent, Welch, Paired and One-Sample

Compare two groups, a before-and-after measurement or a sample against a known value. Paste raw data or type means and SDs, and get t, df, p, the 95% CI, Cohen’s d and a sentence ready for your results section.

✅ No login needed100% freeRuns in your browserYour data stays on your device
T-Test Calculator✅ Free · no login📚 Cite this tool
Your data never leaves your PC. Your data is analysed on your own computer or phone, even when you upload a CSV or Excel file. Nothing is uploaded, stored or seen by Codanics, and no login is needed.
  • PriceFree, no login or sign-up needed
  • Your dataProcessed in your browser, never uploaded
  • Works onPhone, tablet or computer, any modern browser
  • Made byDr. Muhammad Aammar Tufail, Codanics
  • Published14 November 2026
  • Last updated16 November 2026

📚 How to cite this tool

This tool is free. If it helped your thesis, paper, report or assignment, please cite it. It keeps the tools free and helps other students find them.

Citation · APA 7th edition

Tufail, M. A. (2026). T-test calculator [Online tool]. Codanics. Retrieved 16 November 2026, from https://codanics.com/tools/t-test-calculator/

In-text citation: (Tufail, 2026) · Narrative: Tufail (2026)

The access date is today’s date, filled in automatically. Author: Muhammad Aammar Tufail. Published 14 November 2026.

🚀 Follow Codanics channel on WhatsApp for more updatesNew free tools, scholarships, PhD positions and research tips, straight to your phone. Free lessons on YouTube too.

How to use the t-test calculator

  1. Pick the test: independent samples (two separate groups), paired samples (the same people measured twice) or one sample (compare with a known value).
  2. Choose raw data or summary statistics. For raw data, type or paste each group’s values into its box, or use Paste from Excel or Upload CSV / Excel to load your spreadsheet. A long-format sheet (a group column and a value column) is split into the two groups for you.
  3. Choose two-tailed (the usual choice) or one-tailed, and keep Welch’s test unless you have a good reason to assume equal variances.
  4. Click Run t-test and copy the APA sentence. Download the means plot for your thesis.

Which t-test should I use?

DesignExampleTest
Two separate groupsYield of treated vs untreated plotsIndependent samples (Welch)
Same subjects measured twiceBlood pressure before and after a dietPaired samples
One group vs a known valueIs mean IQ in our sample different from 100?One sample
Three or more groupsFour fertilizer dosesANOVA, not several t-tests

Formulas

Welch t = (x̄₁ − x̄₂) / √(s₁²/n₁ + s₂²/n₂) df = (s₁²/n₁ + s₂²/n₂)² / [ (s₁²/n₁)²/(n₁−1) + (s₂²/n₂)²/(n₂−1) ] Student t = (x̄₁ − x̄₂) / √(s_p² (1/n₁ + 1/n₂)), df = n₁ + n₂ − 2 Paired t = d̄ / (s_d / √n), df = n − 1 One sample t = (x̄ − μ₀) / (s / √n) Cohen’s d (x̄₁ − x̄₂) / s_p (paired: d_z = d̄ / s_d)

Assumptions

  • The observations are independent (except for the pairing in a paired test).
  • The data, or the paired differences, are roughly normally distributed. With more than about 30 per group, the t-test is robust to mild non-normality.
  • Student’s test also assumes equal variances. Welch’s test does not, which is why it is the recommended default.
Check your data’s shape first with the descriptive statistics calculator. If the data are strongly skewed and the samples are small, use a Mann–Whitney U or Wilcoxon signed-rank test instead.
Learn the statistics behind these numbers. Codanics has free statistics, R and Python lessons on YouTube and full courses for researchers.

Frequently asked questions

Should I use Welch's or Student's t-test?

Use Welch’s t-test by default. It gives almost the same answer as Student’s test when variances are equal, and it protects you when they are not. Many statisticians recommend skipping the equal-variance check altogether and always using Welch.

How do I report a t-test in APA style?

Report the means and SDs, then t(df) = value, p = value, and an effect size, for example: t(22) = 4.35, p < .001, d = 1.78. This tool writes that sentence for you.

What is the difference between one-tailed and two-tailed?

A two-tailed test checks for a difference in either direction and is the standard choice. Use one-tailed only if you specified the direction before collecting data and a difference in the other direction would be meaningless.

Can I run a t-test from mean and standard deviation only?

Yes. Switch the input to ‘Summary statistics’ and type the mean, SD and n of each group. This is handy for checking published papers or extracting data for a meta-analysis.

What if my p-value is above 0.05?

It means your data do not provide strong evidence of a difference. It does not prove that the groups are the same. Report the effect size and confidence interval so readers can judge the size and precision of the difference.

Is my data uploaded?

No. The test runs entirely in your browser.

Do I need to log in or create an account to use the t-test calculator?

No. There is no login, no sign-up and no email required. Open the page and start using it straight away, for free, on any device.

How do I cite this tool in my thesis or paper?

Use the citation box on this page. In APA 7th edition: Tufail, M. A. (2026). T-test calculator [Online tool]. Codanics. Retrieved [date you used it], from https://codanics.com/tools/t-test-calculator/. BibTeX, RIS (EndNote, Mendeley, Zotero), MLA, Harvard, Chicago and Vancouver formats are also available.

Free guides and courses from Codanics

More free tools

See all free Codanics tools → · Codanics on YouTube · WhatsApp channel

Made by Dr. Muhammad Aammar Tufail, Codanics. First published 14 November 2026, last updated 16 November 2026. Found a bug or have an idea for a new tool? Tell us on the WhatsApp channel or in the comments on YouTube. Results are for learning and planning; check important analyses with a statistician or your supervisor.