Manuel B. Garcia

Manuel B. Garcia serves as the Senior Director for Educational Technology and Digital Learning at FEU Institute of Technology, Manila, Philippines. Read More

Contact Info

1607, FEU Tech Building,
P. Paredes St, Sampaloc,
Manila, Philippines
mbgarcia@feutech.edu.ph

Follow Me

When Is Difference-in-Differences an Appropriate Design Strategy?

Difference-in-differences can estimate intervention effects by comparing outcome changes between treated and comparison groups. Learn when this strategy is appropriate, which assumptions matter, and why having before-and-after data is not enough.

223
When to Use Difference-in-Differences Guide 223 of 1272
01 · The Question

When Can Comparing Changes Between Two Groups Reveal an Intervention Effect?

Suppose a university introduces an AI-supported academic advising system while another university continues using its existing advising procedures. Student retention improves at both institutions, but the improvement is larger at the university that adopted the system.

Can the difference between those improvements be attributed to the intervention?

A simple comparison of retention rates after implementation may be misleading because the universities could have differed before the program began. A before-and-after comparison at the intervention university is also insufficient because retention might have improved for reasons unrelated to the advising system.

Difference-in-differences offers another approach. Instead of comparing outcome levels alone, it compares how outcomes change over time in treated and comparison groups.

However, the method is appropriate only when the comparison group's change provides a credible approximation of how the treated group's outcome would have changed without the intervention. That requirement is more demanding than merely having two groups and two measurement periods.

02 · The Short Answer

Use Difference-in-Differences When the Comparison Group Provides a Credible Counterfactual Trend

In Brief

Difference-in-differences is appropriate when an intervention affects one group but not a suitable comparison group, outcomes are observed before and after implementation, and it is plausible that the groups would have experienced comparable outcome changes without treatment.

The central requirement is the parallel trends assumption, potentially conditional on relevant pretreatment characteristics. Researchers must also consider anticipation, concurrent interventions, changing group composition, treatment spillover, and how intervention timing affects estimation. The method does not automatically remove confounding simply because it compares changes rather than outcome levels.

03 · What You Need to Know

How to Determine Whether Difference-in-Differences Fits a Research Question

What difference-in-differences actually estimates

Difference-in-differences, commonly abbreviated DiD, compares the change in an outcome for a treated group with the corresponding change for a comparison group.

Its basic logic is that some outcome changes would occur even without the intervention. By subtracting the comparison group's change, researchers attempt to remove the portion of the treated group's change attributable to shared background influences.

For example, student retention may improve across universities because of economic conditions, changes in student support, or broader educational policies. A suitable comparison group can provide information about those changes.

However, the method does not automatically isolate the intervention effect. Its causal interpretation depends on whether the comparison group's observed change represents the treated group's counterfactual change.

The basic two-group, two-period calculation

The conventional difference-in-differences estimator subtracts the comparison group's before-and-after change from the treated group's before-and-after change.

Basic Difference-in-Differences Estimator
DiD = (YT,post − YT,pre) − (YC,post − YC,pre)
Y represents the mean outcome; T identifies the treated group; C identifies the comparison group; pre and post identify the periods before and after intervention implementation.
Suppose retention increases from 70% to 82% in the treated group and from 74% to 80% in the comparison group. The treated group improves by 12 percentage points, while the comparison group improves by six. The difference-in-differences estimate is six percentage points.

The six-percentage-point estimate represents the additional observed improvement in the treated group relative to the comparison group.

It can be interpreted as a causal effect under the relevant identification assumptions. Without those assumptions, it remains a descriptive contrast between changes.

When the research question concerns an intervention introduced at a known time

Difference-in-differences is particularly useful for evaluating interventions, policies, or institutional changes introduced to some units but not others.

Examples include universities adopting new student support programs, schools implementing curriculum reforms, hospitals introducing revised clinical protocols, or regions receiving government assistance.

The intervention should be sufficiently well defined that researchers can identify who was treated, when treatment began, and what comparison condition existed.

Uncertain implementation dates or highly variable exposure can complicate interpretation.

Researchers should distinguish formal program announcement, operational implementation, and meaningful exposure when those events occur at different times.

Why a comparison group is necessary

Conventional difference-in-differences requires observations from treated and comparison units.

The comparison group supplies information about outcome changes that might have occurred without the intervention.

However, untreated status alone does not make a group suitable.

For example, universities that do not adopt an AI advising system may differ from adopters in financial resources, student characteristics, institutional leadership, or existing retention trends.

Researchers should investigate whether these differences threaten the intended counterfactual comparison.

The criteria for a credible quasi-experimental comparison group depend on the identification strategy rather than baseline similarity alone.

The parallel trends assumption is central

The parallel trends assumption concerns how the treated and comparison groups would have changed over time if the intervention had not occurred.

In the conventional two-group, two-period setting, it requires equality of the groups' average untreated outcome changes over the relevant period.

This does not require identical baseline outcome levels.

For example, one university may consistently have lower retention than another while both experience similar changes over time. Such differences in levels may be compatible with parallel trends.

Conversely, two universities may have identical retention immediately before treatment but substantially different underlying trajectories.

The assumption concerns counterfactual changes, not merely observed baseline equality.

The parallel trends assumption in difference-in-differences therefore requires careful substantive and empirical assessment.

Why parallel trends cannot be proven from the observed data

The treated group's untreated potential outcomes after intervention are not observed.

Consequently, researchers cannot directly verify whether the treated and comparison groups would have followed parallel trends without treatment.

Several pre-intervention observations can help assess whether historical trajectories were similar and whether important differences were already emerging.

However, similar pre-intervention trajectories do not guarantee that trends would have remained parallel after implementation.

A nonsignificant pre-trend test is also not proof of equivalence. Such tests may have limited power to detect meaningful differences.

Researchers should combine graphical examination, substantive knowledge, institutional histories, and appropriate sensitivity analyses when evaluating the assumption.

When different baseline levels are acceptable

Difference-in-differences can accommodate stable differences in outcome levels between groups.

Suppose University A has retention rates of 70%, 74%, and 78% across three pre-intervention years, while University B has rates of 80%, 84%, and 88%.

Although University B consistently has higher retention, both universities improve by four percentage points annually.

These observed patterns may support a parallel-trends argument, although they do not establish future counterfactual trends.

The distinction is important because selecting comparison groups solely according to the latest baseline mean may produce a weaker comparison than examining their trajectories.

When group composition must remain comparable

Difference-in-differences can use panel data following the same units or repeated cross-sectional data observing different individuals over time.

In either case, researchers must consider whether changes in the observed population influence the outcome comparison.

For example, a university may change its admissions policy at the same time it introduces an AI advising system. The characteristics of incoming students may then differ from those observed before implementation.

Observed changes in retention could partly reflect changes in student composition rather than the advising intervention.

Researchers should define eligibility and sampling consistently, measure relevant pretreatment characteristics, and consider whether compositional changes threaten identification.

Adjustment for variables affected by treatment requires additional care because it may change the estimand or introduce bias.

Why concurrent interventions can invalidate the comparison

Suppose the treated university introduces an AI advising system and expands financial assistance during the same academic year.

If the comparison university does not introduce similar assistance, its outcome change may not represent the treated university's counterfactual trend.

The estimated difference-in-differences effect could reflect both interventions.

Researchers should document other policies, institutional changes, and external events occurring during the evaluation period.

If two interventions are inseparable in the observed data, the estimand may concern their combined effect rather than the effect of either component individually.

Anticipation can compromise pretreatment observations

Participants and institutions may change their behavior before the official intervention date if they know treatment is forthcoming.

For example, teachers may begin preparing instructional materials before a digital platform becomes operational. Administrators may reorganize advising procedures after a new system is announced.

If these changes affect outcomes, periods classified as untreated may already contain intervention-related effects.

Researchers should investigate announcement dates, preparatory activities, and implementation lags.

Where justified, anticipation periods can be explicitly modeled or excluded from particular comparisons according to a prespecified strategy.

Why treatment spillover matters

Difference-in-differences commonly assumes that the comparison group's outcomes are not affected by the treated group's intervention in ways that undermine the intended estimand.

However, interventions can produce spillover.

For example, teachers at untreated schools may adopt instructional strategies shared by colleagues at treated schools.

Alternatively, a regional policy may affect neighboring institutions through student transfers, resource competition, or information sharing.

Such interference can change comparison outcomes and complicate the causal interpretation.

Researchers should assess whether the chosen comparison group remains meaningfully untreated and whether indirect effects are part of the research question.

When two periods are enough and when more are useful

A basic difference-in-differences estimate can be calculated using one pretreatment and one post-treatment period for each group.

However, additional pretreatment periods are often valuable because they allow researchers to examine historical trajectories and identify potential deviations before intervention.

Multiple post-treatment periods can reveal whether effects develop, persist, or diminish.

More observations do not automatically establish parallel trends or eliminate confounding, but they can improve the assessment of temporal patterns.

The number and spacing of periods should reflect the outcome's natural timescale, intervention implementation, and analytical objectives.

When staggered adoption requires different estimators

In many policy evaluations, institutions adopt an intervention at different times rather than simultaneously.

These settings are commonly called staggered adoption designs.

Conventional two-way fixed-effects regressions may produce difficult-to-interpret weighted averages when treatment effects vary across adoption cohorts or exposure durations.

Some comparisons may implicitly use already-treated units as controls for newly treated units.

Callaway and Sant'Anna developed methods for estimating group-time average treatment effects, while Sun and Abraham examined event-study estimation under heterogeneous treatment effects.

These approaches can provide more transparent estimates when their identification assumptions are satisfied.

Researchers should specify whether comparison units are never treated or not yet treated, how cohort-specific effects are estimated, and how effects are aggregated.

The fact that an intervention was introduced in stages does not justify applying a conventional two-way fixed-effects model without examining these issues.

How to interpret the estimand

Difference-in-differences commonly targets an average treatment effect for the treated population under the relevant assumptions.

However, the precise estimand depends on the study design, treatment timing, comparison group, and aggregation procedure.

For example, an evaluation of AI advising adoption may estimate the average effect among universities that implemented the program, rather than the effect that would occur at every university.

When effects differ across institutions, exposure durations, or student populations, the target population matters.

Researchers should state the estimand before estimation and avoid interpreting a cohort-specific or local effect as universally applicable.

Why statistical significance does not establish validity

A statistically significant difference-in-differences estimate may still be biased if the parallel trends assumption is implausible or concurrent interventions affect treated and comparison groups differently.

Large datasets can produce precise estimates of invalid comparisons.

Conversely, a credible design may produce an imprecise estimate because the number of institutions or the available identifying variation is limited.

Researchers should distinguish statistical precision from causal identification.

When treatment is assigned at the school, university, or regional level, standard errors must also account appropriately for the dependence structure. Having many individual observations does not automatically provide many independent treatment-assignment units.

What diagnostics and sensitivity analyses are useful?

Researchers should examine pretreatment outcome trajectories and investigate whether major concurrent changes differ between groups.

Event-study analyses may help describe effects relative to treatment timing, but their interpretation depends on the estimator and assumptions.

Placebo intervention dates or negative control outcomes may reveal particular threats when substantively justified.

Sensitivity analyses can assess how conclusions change under plausible violations of parallel trends or alternative comparison definitions.

However, passing diagnostic checks does not prove that all assumptions hold.

The strongest evaluation combines a defensible assignment narrative, appropriate estimation, and transparent assessment of remaining uncertainty.

When difference-in-differences is not appropriate

Difference-in-differences may be inappropriate when no credible comparison group exists, treatment timing is poorly defined, or treated and comparison units would plausibly have followed substantially different counterfactual trends.

It may also be unsuitable when major concurrent interventions cannot be separated, measurement procedures change inconsistently, or anticipation and spillover undermine the comparison.

In such circumstances, researchers should consider whether regression discontinuity, interrupted time series, or another design better matches the assignment mechanism.

If no defensible identification strategy is available, descriptive or associational conclusions may be more appropriate.

Watch Out

Difference-in-differences does not become causal merely because the calculation subtracts two changes. Its validity depends on whether the comparison group's outcome change represents the treated group's counterfactual change under the specified assumptions.

04 · A Practical Example

Evaluating an AI-Supported Advising Program Using Difference-in-Differences

Hypothetical Example

Student retention at two university groups

A university system introduces an AI-supported advising program at five campuses. Five comparison campuses continue existing advising services.

All campuses report retention using the same definition. For illustration, the intervention campuses' average retention increases from 72% to 84%, while comparison campuses' average retention increases from 75% to 81%.

The values are hypothetical and are intended to illustrate the calculation rather than represent empirical findings.

Campus group Before intervention After intervention Observed change
Intervention campuses 72% 84% +12 percentage points
Comparison campuses 75% 81% +6 percentage points
Difference-in-Differences Calculation
DiD = (84 − 72) − (81 − 75) = 6 percentage points
The result represents the additional observed improvement among intervention campuses relative to comparison campuses.
The intervention group improves by 12 percentage points, while the comparison group improves by six. Their difference in changes is six percentage points.
Define the estimand. The researchers seek the average effect of introducing AI-supported advising among the campuses receiving it.
Investigate treatment assignment. The team documents why five campuses adopted the system and whether those reasons are related to retention trends.
Examine pretreatment trajectories. Retention data from several earlier academic years are used to assess the plausibility of parallel counterfactual trends.
Investigate competing explanations. Changes in financial assistance, admissions, student support, and measurement procedures are reviewed.
Estimate uncertainty appropriately. The analysis accounts for campus-level treatment assignment and the limited number of independent campuses.
Interpret conditionally. The six-percentage-point estimate is treated as causal only to the extent that the identification assumptions are defensible.

Interpretation: The observed difference-in-differences is six percentage points. Under the relevant assumptions, it can estimate the intervention's average effect for the treated campuses.

However, if intervention campuses were already improving more rapidly or introduced another retention policy at the same time, the estimate may overstate the effect of AI-supported advising.

The arithmetic is straightforward. Establishing that the comparison captures the untreated counterfactual requires substantially more methodological work.

05 · What Researchers Often Get Wrong

Common Mistakes When Using Difference-in-Differences

Misconception

Two Groups and Two Periods Automatically Justify Difference-in-Differences

The data structure permits the calculation, but causal identification requires a credible comparison and defensible assumptions about untreated outcome changes.

Misconception

The Groups Must Have Identical Baseline Outcomes

Difference-in-differences can accommodate differences in outcome levels. The central concern is whether counterfactual changes would have been comparable.

Misconception

Similar Pre-Trends Prove Parallel Trends

Observed pretreatment patterns can support an identification argument but cannot establish unobserved counterfactual changes after treatment.

Misconception

Fixed Effects Remove Every Source of Confounding

Unit and period fixed effects address particular stable differences and common time changes. They do not automatically eliminate differential time-varying confounding.

Misconception

Conventional Two-Way Fixed Effects Is Always Suitable for Staggered Adoption

Heterogeneous treatment effects can produce problematic comparisons and weighting. The estimator should reflect adoption timing and the intended estimand.

Misconception

A Statistically Significant Estimate Proves Causality

Statistical significance does not establish the validity of parallel trends or rule out competing interventions and selection mechanisms.

06 · What This Means for You

Choose Difference-in-Differences Only When the Counterfactual Trend Is Defensible

Begin by identifying the intervention, treatment timing, comparison group, and causal estimand. Then examine whether the comparison group's untreated outcome trajectory plausibly represents the treated group's counterfactual trajectory.

Use multiple pretreatment periods where available, investigate competing interventions, and select an estimator appropriate to the adoption structure.

A practical difference-in-differences decision framework

If treated and comparison groups are observed before and after intervention
Consider difference-in-differences, subject to the identification assumptions.
If baseline outcome levels differ but counterfactual trends are plausibly comparable
Difference-in-differences may remain appropriate because identical outcome levels are not required.
If adoption occurs at different times
Use an estimator that accommodates staggered timing and potential treatment-effect heterogeneity.
If concurrent policies differentially affect treated units
Investigate whether the separate intervention effect can be identified or whether the estimand concerns a combined package.
If counterfactual trend assumptions cannot be defended
Consider another design or limit conclusions to descriptive differences in observed changes.

Difference-in-differences is most useful when the research question concerns an intervention effect and the comparison group offers a credible account of how outcomes would have changed without treatment.

The design should be justified through the assignment mechanism and substantive evidence, not merely through the availability of before-and-after observations.

07 · A Quick Checklist

Before Selecting Difference-in-Differences

Before finalizing the design, check:
Define the intervention, treatment timing, outcome, population, and causal estimand.
Identify treated and credible untreated or not-yet-treated comparison units.
Confirm comparable outcome measurement before and after intervention.
Investigate treatment assignment and reasons for differences between groups.
Assess the plausibility of parallel counterfactual trends using substantive and pretreatment evidence.
Identify anticipation, spillover, concurrent interventions, and changing participant composition.
Choose an estimator appropriate for simultaneous or staggered adoption.
Account for the treatment-assignment level and relevant dependence when estimating uncertainty.
Prespecify appropriate diagnostics and sensitivity analyses.
Interpret the estimate causally only to the extent supported by the identification assumptions.
08 · Frequently Asked Questions

Frequently Asked Questions About Difference-in-Differences Design

When should difference-in-differences be used?

When treated and comparison groups have relevant pre- and post-intervention outcome observations and the comparison group's change provides a defensible estimate of the treated group's counterfactual change.

Does difference-in-differences require random assignment?

No. It is commonly used for nonrandomized interventions and policies. Causal interpretation depends on assumptions about counterfactual trends and other relevant conditions.

Do the groups need identical baseline scores?

No. Different baseline levels can be compatible with difference-in-differences. The key issue is comparability of untreated outcome changes under the design's assumptions.

Can difference-in-differences use only two time periods?

Yes, a basic estimator can use one pre- and one post-treatment period. Additional pretreatment periods are often valuable for assessing historical trajectories.

Can difference-in-differences be used with repeated cross-sectional data?

Yes, provided the populations and measurements are defined appropriately and changes in composition do not undermine the intended comparison.

What if institutions adopt the intervention in different years?

Staggered adoption requires attention to cohort-specific effects, comparison groups, and heterogeneous treatment effects. Modern staggered difference-in-differences estimators may be appropriate.

Can a nonsignificant pre-trend test prove parallel trends?

No. Failure to reject a pre-intervention trend difference does not establish equality of unobserved counterfactual trends.

Is difference-in-differences always better than a simple before-and-after study?

It can provide a more credible comparison when its assumptions are defensible. An unsuitable comparison group or major differential concurrent event can still undermine causal inference.

09 · The Bottom Line

Difference-in-Differences Is Appropriate When Changes Can Be Compared Credibly

The Bottom Line

Difference-in-differences is appropriate when researchers can compare outcome changes between treated and comparison groups and defend the assumption that their untreated counterfactual trends would have been comparable.

The method is not simply a subtraction formula. Its validity depends on treatment assignment, comparison-group credibility, intervention timing, measurement consistency, and the absence or appropriate handling of competing influences. Choose it when those conditions support the intended causal effect, not merely because before-and-after data are available.

10 · Sources and Further Reading

Foundational Literature on Difference-in-Differences

11 · Cite this Guide

How to Cite This Guide

This guide is intended to be read, shared, and used in research, teaching, and academic work. If you draw on its ideas, explanations, or other content, please acknowledge the source by citing the guide. Doing so gives appropriate credit and helps your readers locate the original resource.

Has the Field Guide helped your research?

If a guide helped clarify a question, inform a research decision, or move your work forward, I would love to hear about your experience. Your story may also help other researchers discover the Field Guide.

Share Your Experience
Takes only a few minutes