TL;DR
Internal validity asks whether the comparison in a study really measures the effect of the treatment on the people studied. A study has it when the treated and untreated groups would have looked the same, apart from the treatment, had nothing been done. When they differ before treatment, or change in different ways for other reasons, the gap between them mixes the treatment with those differences. Good design is mostly the work of making the comparison fair.
Where you'll see it: in any evaluation of a policy, campaign, reform or institution, where the question is "did this cause that", and the answer depends on how the groups were formed and what happened to them.
Intuition
A fair race
Imagine testing whether a new coaching programme makes runners faster. You let runners sign up, and the keen ones join. Afterwards, the programme group is faster than the non-programme group. Is the coaching responsible? Maybe. But the keen runners were already faster, or would have improved more anyway. The comparison is not fair, because the two groups started in different places.
A study has internal validity when the comparison is fair: the only systematic difference between the groups is the treatment. Think of it as a race where the starting line is the same for everyone. Internal validity is about the start and the rules of the race within the study. It is separate from whether the result would hold for other people or other places, which is external validity.
flowchart LR P["people in the study"] --> A["assignment: who gets treated"] A --> T["treated group"] A --> C["comparison group"] T --> D["observed difference in outcomes"] C --> D B["baseline differences between the groups"] --> D
The observed difference is the treatment effect plus whatever baseline differences and other changes the assignment process brought in. Internal validity is the condition that the last term is small or zero.
Why it is a separate question
A result can be internally valid and still not generalise. A well-run experiment on one city's council may show a clean effect that does not carry to another country. The reverse is also possible: a large, representative survey can produce a result that is externally broad but internally invalid, because the comparison inside it was confounded. Keeping the two questions apart stops a reader from taking a representative sample as proof of causation.
The math
Use the potential outcomes notation from Causal Inference. For each unit , is the outcome if treated and is the outcome if not. The treatment indicator is 1 if unit is treated and 0 otherwise. Only one of the two potential outcomes is ever observed for a given unit, so the causal effect of interest is a comparison of two groups.
The average treatment effect on the treated, , is
It is the average effect among the people who actually received treatment. The quantity a study can compute from observed data is the difference in group means:
Write the observed outcome as . For the treated group the observed mean is , and for the untreated group it is . Add and subtract , the outcome the treated would have had without treatment:
The first term is the effect we want. The second term is the gap in untreated outcomes between the two groups before treatment. That gap is Selection Bias. A study is internally valid for the ATT when the selection term is zero, and a design earns that by making the untreated outcomes of the two groups match in expectation.
Randomisation does this. If assignment is independent of potential outcomes, then , the second term vanishes, and the simple difference in means estimates the average treatment effect. Observational studies have to argue for this condition rather than create it.
Worked examples
Four units A, B, C and D have these outcomes:
| unit | effect | ||
|---|---|---|---|
| A | 2 | 5 | 3 |
| B | 4 | 6 | 2 |
| C | 1 | 3 | 2 |
| D | 3 | 7 | 4 |
The average effect over all four is .
Case 1, non-random assignment: A and B are treated, C and D are not.
- Treated observed outcomes are for A and B: and , mean .
- Untreated observed outcomes are for C and D: and , mean .
- Naive difference: .
- True effect on the treated: .
- Selection term: mean of A and B is , minus mean of C and D, which is . The term is .
- Check: , the naive difference. The study overstates the effect by a full point, because the treated group was already better off.
Case 2, random assignment: each unit is treated with probability one half. Across all ways of assigning treatment, the average treated outcome is the average of over all four units, , and the average untreated outcome is the average of , . The expected naive difference is , exactly the true average effect. Any single draw can miss, but the design is not biased.
Interpretation: the same four people and the same effects give a biased answer under one assignment rule and an unbiased one under another. What changed is only the assignment process, which is the source of internal validity.
These numbers are invented for illustration. Suppose some cities adopted a participatory budgeting program and others did not, and the outcome is turnout in local elections, in percent.
| before | after | change | |
|---|---|---|---|
| adopting cities | 48 | 55 | +7 |
| non-adopting cities | 41 | 44 | +3 |
- A simple comparison after adoption gives points.
- Adopting cities already had higher turnout before the program: points.
- Difference in differences: points.
- Check: . Most of the simple comparison is the baseline gap that existed before anyone adopted anything.
The difference-in-differences estimate is internally valid only under the parallel trends assumption: without the program, adopting cities would have risen by the same 3 points as the others. That is a claim about the world, not something the table can prove. If adopters were already on a steeper upward path, the 4 points is still too high.
Interpretation: the program may have raised turnout by about 4 points, but the simple after-only comparison of 11 points would have credited it with most of a difference that predated it.
Tradeoffs and failure modes
Internal validity is threatened in predictable ways. Most of them are versions of the selection term above.
- Selection. People or places choose, or are chosen, for treatment in ways related to the outcome. This is the main threat in observational work.
- Confounding. A third factor drives both treatment and outcome, as in Confounding Bias.
- Reverse causation. The outcome changes the treatment, so the arrow runs the other way too.
- Measurement error. The treatment or outcome is recorded with error in a way that differs between groups.
- Attrition. People drop out of the study in ways related to treatment, so the groups that remain differ from the groups assigned.
- Spillovers. Treated units affect untreated ones, so the comparison group is not clean.
| Design | What it protects against | What it does not fix |
|---|---|---|
| Randomised experiment | Selection and confounding, in expectation | Attrition, spillovers, and results that only hold in the study population |
| Difference in differences | Fixed differences between groups | Trends that differ between groups before treatment |
| Regression discontinuity | Selection around a cutoff | Effects far from the cutoff |
| Instrumental variables | Unmeasured confounding of the treatment | Weak instruments and a strong exclusion assumption |
| Matching or regression on observables | Confounding by measured factors | Anything unmeasured, which is the usual worry |
A common mistake is to treat a well-controlled regression as if it had the same validity as an experiment. Controls only remove the bias from variables you measured, and an omitted variable can still produce Omitted Variable Bias. A study should say which threat it is most worried about and which design answers that threat. A clear statement of remaining threats is part of internal validity, not a weakness to hide.
History
The distinction between internal and external validity was popularised by Donald Campbell and Julian Stanley in their 1963 book on experimental and quasi-experimental designs. They listed threats such as history, maturation, testing and selection, and argued that a study should be judged by how well it rules these out before anyone asks whether its result generalises. Thomas Cook and Campbell extended the framework in 1979 in a book on quasi-experimentation, which is still the standard reference for social-science designs.
The underlying idea that randomisation makes comparisons fair goes back to Ronald Fisher's work on agricultural experiments in the 1920s and 1930s. Donald Rubin's potential outcomes framework, from the 1970s, gave the formal language used above, and Paul Holland's 1986 paper made the link between that framework and causal inference explicit. The concept caught on because it gives researchers a checklist for asking whether their comparison answers the question they care about.