← 8. Causal effects
Two-stage least squares
Try this analysis →

Two-Stage Least Squares (2SLS)

A method that uses an instrumental variable to estimate a causal effect while accounting for the endogeneity between years of education and wages.

EndogeneityFirst- and second-stage regressionsWeak instrumentsCausal inference

Distance to collegeInstrument ZYears of educationEndogenous variable XHourly wageOutcome YStage 1Stage 2No path: distance → wage ✕

Do people with more years of college education also earn more? Can you tell whether higher wages are due to the years of education or to underlying ability or family background? If having a college near home affects how long people stay in school, could you use that in the analysis?

When an explanatory variable is tangled up with other, unobserved factors, two-stage least squares (2SLS) is the method that uses an instrumental variable to estimate the change in the explanatory variable and then uses that change to find the effect on the outcome.

Ordinary regression estimates the conditional relationship between years of education and wages, but if there are omitted variables such as ability or family background, or possible reverse causation in the choice of education, it's hard to read that coefficient directly as a causal effect. 2SLS goes through two rounds of estimation to use the part of the endogenous years of education that is linked to the instrument. The instrument must, however, satisfy relevance and the exclusion restriction.

2SLS is used in labor economics, the economics of education, health and policy evaluation, and other fields. In this article we'll take the distance from home to a college as a candidate instrument to look at the relationship between years of education and wages, and cover what the two stages mean, the key assumptions, how to read the results table, and how it differs from OLS and instrumental variable analysis.

SECTION 1

What is two-stage least squares (2SLS)?

It estimates an endogenous explanatory variable's effect from the variation explained by an instrument.

2SLS is the standard estimation method for linear instrumental variable models. In stage 1, years of education, the endogenous variable, is explained by the instrument and appropriate control variables; in stage 2, the variation in years of education explained by the instrument is used to estimate the effect on wages.

The intuition is often introduced by plugging the predicted years of education into a second regression, but the actual standard errors and confidence intervals must be computed with a dedicated estimator that reflects the whole 2SLS estimation process. You should not use the second-stage standard errors from simply running ordinary regression twice.

SECTION 2

Why do you need 2SLS?

Because the correlation between years of education and wages alone can't tell you the causal effect of education.

Years of education can be associated with a person's ability, academic inclination, family finances, regional characteristics, and so on. If these factors also affect wages, the OLS coefficient on years of education can include influences other than the effect of education.

For example, living near a college may make people more likely to stay in school longer, but if areas close to colleges are themselves places with higher incomes or better job opportunities, distance may not be a valid instrument. So the reason for using 2SLS and the reason the instrument holds up need to be explained separately.

SECTION 3

How does 2SLS work?

Stage 1 finds the instrument-related variation in X, and stage 2 estimates the effect on Y.

How much do wages change with more years of education?Example of two-stage estimation with distance to college as a candidate instrumentDistance to collegeInstrument ZYears of educationEndogenous variable XHourly wageOutcome YStage 1Stage 2The key assumption: no separate path from distance to college → wagesA diagram to explain the concept · it does not show that the instrument is valid
A 2SLS concept diagram connecting distance from home to college (Z), years of education (X), and wages (Y).
Stage 1: years of education = constant + instrument × coefficient + controls × coefficients + error
Stage 2: log hourly wage = constant + instrument-explained years of education × effect + controls × coefficients + error

In practice, 2SLS uses the variation obtained by projecting years of education onto the instrument and the exogenous control variables. The same set of control variables must be used in both stages, and the predicted values in stage 2 are not simply treated as if they were new observations.

SECTION 4

Real-world example: the effect of years of education on wages

We use access to college as a candidate instrument in hypothetical data on adult workers.

Assume a study that observed 600 hypothetical adult workers. Years of education is defined as the total years of formal schooling, and the wage as the natural log of the hourly wage. The candidate instrument is the distance from the place a person lived as a teenager to the nearest four-year college. All numbers are examples for learning.

ItemMeasurement exampleRole
Years of educationYears of formal schooling completedPossibly endogenous explanatory variable X
Log hourly wageNatural log of the hourly wageOutcome Y
Distance to the nearest collegekm from teenage homeCandidate instrument Z
Age, sex, regional characteristicsObserved background factorsCandidate exogenous controls
Analysis sample600 workersUnit of observation

Access to college may be related to the opportunity to go on to school, but a region's industrial structure or educational environment may also affect wages directly. So here we only explain the procedure for using a candidate instrument, and we don't assume the exclusion restriction has been verified.

SECTION 5

What conditions does 2SLS require?

The instrument has to be strong and valid before the estimate can be interpreted causally.

Key conditionMeaningWhat to examine in the example
RelevanceInstrument Z is related to years of education XFirst-stage relationship between distance to college and years of schooling
IndependenceZ is independent of unobserved confounders that affect the outcomeFamily background, choice of location, labor market structure
Exclusion restrictionZ affects wages through no path other than years of educationRegional development and job opportunities near colleges
Functional formLinear model, with suitable definitions of variables and controlsCheck the units of log wages and years of schooling
Additional assumptions such as monotonicityNeeded to interpret specific causal effects such as the LATEDirection of education choices in response to changes in distance
Caution: Even if distance to college significantly predicts years of education, that alone does not satisfy independence or the exclusion restriction.
SECTION 6

In what order do you run a 2SLS analysis?

Choose the instrument, check first-stage strength, estimate the second-stage effect, then run diagnostics.

① Define the variables and the causal assumptions

Set years of education (X), log wages (Y), distance to college (Z), and background controls, and examine other paths through which Z might affect Y.

② Estimate the first-stage regression

Explain years of schooling with distance to college and the controls. Check information on the relevance and strength of the instrument, such as the partial F statistic.

③ Estimate the effect in the second stage

Use a dedicated IV/2SLS estimator to produce the effect of years of education on wages along with correct standard errors and confidence intervals.

④ Compare with ordinary regression and report the limitations

Compare the OLS and IV estimates, but don't conclude that 2SLS must be right just because the estimates differ. Address weak instruments and possible violations of the exclusion restriction separately.

SECTION 7

What do you check in the first-stage regression?

See whether distance to college creates enough variation in years of education.

First-stage itemHypothetical result for learningHow to read it
Coefficient on distance to college−0.12 years/kmEach additional 1 km of distance goes with fewer years of education
Partial F statistic16.4A measure of the strength of first-stage relevance
Sample size600Same observations as in the second stage

F = 16.4 is a hypothetical value for illustration. An F above 10 does not always mean you're safe; consider weak-instrument diagnostics and robust inference suited to the conditions of the analysis, such as heteroskedasticity or clustered data.

SECTION 8

How do you interpret the second-stage results?

In a log wage model, the effect of one more year of education can be converted to a percentage.

Estimation methodCoefficient for one more year of education95% confidence interval (hypothetical)
Ordinary OLS0.065[0.049, 0.081]
2SLS0.091[0.018, 0.164]

The hypothetical 2SLS coefficient of 0.091 can be read as hourly wages being about 9.5% higher for each additional year of education (exp(0.091) − 1 ≈ 0.095). As a simple approximation, it's about 9.1%. The numbers here are illustrative values, not results from an actual fit.

To call this a causal effect, the instrumental variable assumptions must hold. And if the effect differs from person to person, the IV result may be a local effect for the group that responds to the instrument, so don't generalize it as an average effect for everyone.

SECTION 9

What graph do you use to compare OLS and 2SLS results?

Look not just at the difference in coefficients but at the width of the confidence intervals and the uncertainty.

Log wage coefficient for one more year of education · hypothetical results0.000.040.080.120.16OLS2SLS0.0650.091
Hypothetical estimates for learning, shown on the same axis. Dots are coefficients and horizontal lines are 95% confidence intervals.

The 2SLS confidence interval can be wider than the OLS one. That's because using only the limited variation that comes through the instrument can lower the precision of the estimate. A bigger coefficient doesn't simply mean a better analysis.

SECTION 10

What to watch out for in 2SLS

You need to check not just the computations but whether the instrument is appropriate and how inference is done.

Could distance to college affect wages directly?

If areas near colleges have more jobs or higher wages, distance can be linked to wages through more than years of education. Alternative paths like this are a major threat to the exclusion restriction.

Are you using a weak instrument?

If first-stage relevance is weak, the 2SLS coefficient and the usual confidence intervals can become very unstable. Consider diagnostics suited to your data structure and tests that are robust to weak instruments.

Did you calculate the standard errors correctly?

Don't run the second stage as a separate OLS and report its standard errors as they are. Use a 2SLS estimator with appropriate heteroskedasticity-robust or cluster-robust standard errors.

Are the estimated population and the scope of generalization clear?

It may be the effect for the group whose education choices change with access to college. Whether it generalizes to the whole population has to be judged separately, based on the study design and identifying assumptions.

SECTION 11

How does it differ from other analyses?

IV is an identification strategy, and 2SLS is the standard estimation method for carrying it out.

MethodPurposeWhat sets it apart
OLS regressionEstimates the observed education–wage relationshipWith endogeneity, a causal interpretation is hard
Instrumental variable (IV) approachTries to identify the causal effect from exogenous variationEmphasizes instrument relevance, independence, and the exclusion restriction
Two-Stage Least Squares (2SLS)Estimates the coefficients of a linear IV modelNeeds the two-stage procedure and correct inference
Regression with controlsAdjusts for observed background factorsDoesn't automatically remove unobserved confounding
Difference-in-differences (DID)Compares the before–after change in two groups around a policyRelies on other assumptions, such as parallel trends

You don't have to think of instrumental variable analysis and 2SLS as entirely separate, competing methods. 2SLS is one of several estimators you can use once a suitable instrumental variable design is in place.

SECTION 12

How do you report 2SLS results?

Present first-stage strength, the second-stage effect, and the assumptions and limitations together.

In a paper or report, lay out the variable definitions, the rationale for the instrument, the sample and controls, first-stage relevance and strength diagnostics, the 2SLS coefficient and confidence interval, how standard errors were handled, the comparison with OLS, and the weak points of the exclusion restriction.

Example report sentence for a paper

To account for possible endogeneity between years of education and wages, two-stage least squares (2SLS) was examined using the distance from teenage home to college as a candidate instrument. In the hypothetical results for learning, the first-stage partial F statistic was 16.4, and the 2SLS coefficient on years of education was 0.091 (95% CI [0.018, 0.164]). This corresponds to hourly wages about 9.5% higher for each additional year of education. However, these values are hypothetical figures set up to explain the analysis, and a causal interpretation requires separate evidence for the exogeneity of access to college and the exclusion restriction.

Don't write that a causal effect has been proven just because relevance was confirmed. In particular, discuss other paths through which regional differences in access to college could affect wages.

SECTION 13

Where can you use 2SLS?

Use it in studies that have both an endogeneity problem and a convincing candidate instrument.

FieldEffect of interestCandidate instruments to examine
Education & laborEffect of years of education on wagesAccess to college, institutional changes
Health economicsEffect of treatment use on healthExogenous variation in the supply of health services
TransportationEffect of transit access on car useHistorical placement of infrastructure
Policy evaluationEffect of participation or support on outcomesEligibility thresholds or random assignment

The instruments in the table are only candidates a study could examine. Whether the exclusion restriction holds, and for whom the effect is identified, has to be checked anew in each study.

✓ Wrap-up

The heart of 2SLS is not the trick of running two regressions but how you interpret the variation the instrument creates.

To interpret the relationship between years of education and wages causally, you need to examine both the estimation procedure and the identifying assumptions.


Just because people with more years of education earn more, you can't immediately conclude that adding years of education will raise wages by that much. Two-stage least squares is an estimation method that uses variation linked to an instrument to deal with the endogeneity of years of education. The key is that stage 1 checks how much distance to college explains years of education, and stage 2 estimates the relationship with wages based on that variation.

But finishing the two stages of calculation doesn't automatically confirm a causal effect, because distance to college may also be related to the local labor market, family background, and where people choose to live. So researchers need to examine not only the instrument's relevance and strength but also independence and the exclusion restriction, and to be clear about the confidence interval and the scope of what is being estimated. Without a valid instrument, it is better not to claim a causal relationship from 2SLS numbers alone.

KEY TAKEAWAY

2SLS estimates the effect on wages using the variation in years of education explained by the instrument. First-stage relevance and weak-instrument diagnostics are necessary, but they don't replace independence and the exclusion restriction. Report the 2SLS estimate, confidence interval, and standard errors together with the limits of a causal interpretation.