Mediators: testing indirect effects with bootstrapping and PROCESS Model 4
This article explains why bootstrapping has replaced the Baron and Kenny approach, shows how to run PROCESS Model 4 in SPSS and reads each output block with one consistent numerical example.
Quick summary
- A mediator M explains the mechanism X → M → Y; the indirect effect is a × b, and with OLS regression on the same sample: c = c′ + ab.
- A significant total effect c is not required to test mediation (Zhao, Lynch & Chen, 2010; Hayes, 2022).
- Use 5.000 bootstrap samples and a 95% percentile confidence interval: if the interval doesn't contain 0, the indirect effect is significant.
- In SPSS: install PROCESS v4, choose Model 4, and read the Indirect effect(s) of X on Y block with BootLLCI and BootULCI.
- Example: ab = 0,2132, 95% CI [0,142; 0,291], c′ = 0,18 (p = 0,012), same sign, so it is complementary mediation.
What a mediator is, and paths a, b, c, c′
Mediator (mediator, M) answers how X affects Y by what means: X changes M, and M changes Y. A moderator (W) answers how strong the effect of X on Y is, for whom and when: W changes the size or direction of the X → Y relationship and is tested with the X × W interaction term, not an indirect effect (Baron & Kenny, 1986; Hayes, 2022).
- a: the coefficient of X when regressing M on X.
- b: the coefficient of M when regressing Y on both X and M.
- c′ (direct effect): the coefficient of X in that same equation.
- c (total effect): the coefficient of X when regressing Y on X alone.
This identity holds exactly when the equations are estimated with OLS, M and Y are continuous, and every equation uses the same sample (same observations, same controls) (Hayes, 2022). With a binary Y (logistic regression) it no longer holds.
From Baron & Kenny and Sobel to bootstrapping
The causal steps of Baron & Kenny (1986)
The classic approach requires: (1) c is significant; (2) a is significant; (3) b is significant controlling for X; (4) c′ is smaller than c, and if c′ is no longer significant it is called "full mediation". This approach is no longer recommended. Condition (1) is unnecessary: an indirect effect can exist when the total effect is not significant, e.g. when c′ and ab have opposite signs and cancel out, or when the test of c lacks power (Zhao, Lynch & Chen, 2010; Hayes, 2022). More importantly, these steps never directly test the quantity of interest, ab.
The Sobel test
The Sobel test (Sobel, 1982) assumes the sampling distribution of ab is normal. In practice the product of two coefficients is usually skewed, so Sobel has low power and easily misses real indirect effects (Preacher & Hayes, 2008). In the example below (SEa = 0,049; SEb = 0,055), z ≈ 6,10, but this should be treated as supplementary, not the main evidence.
Bootstrap
Bootstrapping resamples n observations with replacement from your own data, 5.000 times; each time a, b and ab are re-estimated. The 5.000 values of ab form an empirical distribution with no normality assumption. The 95% percentile interval takes the values at the 2,5 and 97,5. percentiles If the confidence interval doesn't contain 0, the indirect effect is statistically significant (Preacher & Hayes, 2008; Hayes, 2022).
How to run PROCESS Model 4 in SPSS
First compute the mean score for each construct (X, M, Y) after the scales pass reliability and validity, as described in the article reading SPSS regression output. Use short unaccented variable names (e.g. CLDV, HL, TT) to avoid errors when running the macro.
Installing PROCESS v4 (Hayes)
- Download PROCESS for SPSS from processmacro.org and unzip it; the file you need is
process.spd. - On Windows you may need to open SPSS with Run as administrator to install it.
- Go to
Extensions → Utilities → Install Custom Dialog (Compatibility mode)...then chooseprocess.spd. - After installing, open
Analyze → Regression → PROCESS v4.x by Andrew F. Hayes.
Setting up the dialog
- Y variable:
TT; X variable:CLDV; Mediator(s) M:HL. - Model number: 4; Confidence intervals: 95; Number of bootstrap samples: 5000.
- Options: tick Show total effect model; add the standardised coefficient/effect size option if needed (the option names differ slightly between versions).
If you use syntax, open process.sps and run all of it once to define the macro, then run:
process y=TT/x=CLDV/m=HL/model=4/total=1/boot=5000/seed=31216.
Reading the PROCESS output block by block
- OUTCOME VARIABLE: HL: regress M on X. The coefficient on the line
CLDVis a = 0,52. - OUTCOME VARIABLE: TT: regress Y on X and M. Line
HLis b = 0,41; lineCLDVis c′ = 0,18. - TOTAL EFFECT MODEL: regress Y on X alone. Coefficient
CLDVis c = 0,393; check that c = c′ + ab. - TOTAL, DIRECT, AND INDIRECT EFFECTS OF X ON Y: the most important summary block, with the two parts below.
Direct effect of X on Y
Effect se t p LLCI ULCI
.1800 .0711 2.5316 .0119 .0401 .3199
Indirect effect(s) of X on Y:
Effect BootSE BootLLCI BootULCI
HL .2132 .0380 .1420 .2910
Effect is the estimate of ab; BootSE is the bootstrap standard error; BootLLCI and BootULCI are the lower and upper bounds of the 95% confidence interval. The interval [0,142; 0,291] doesn't contain 0, so satisfaction is a significant mediator. Note the Indirect effect section has no p-value: the conclusion rests on the confidence interval.
Classifying results per Zhao, Lynch & Chen (2010)
| Type | ab | c′ | Interpretation |
|---|---|---|---|
| Complementary mediation | Significant | Significant, same sign as ab | Mediation; there may be other mediators not included |
| Competitive mediation | Significant | Significant, opposite sign to ab | Mediation; an opposing mechanism is probably missing |
| Indirect-only | Significant | Not significant | Mediation; the theoretical framework is consistent with the data |
| Direct-only | Not significant | Significant | No mediation through M |
| No effect | Not significant | Not significant | No mediation and no direct effect |
In the example, ab is significant (the interval doesn't contain 0), c′ = 0,18 is significant (p = 0,012) and both are positive, so this is complementary mediation. Hayes (2022) advises against the "full/partial mediation" labels, since whether c′ is significant depends heavily on sample size; report the size and confidence intervals of ab and c′. The ratio ab/c (here about 54%) is also unstable when c is small, so use it only for reference.
Multiple mediators, SmartPLS and the limits of causality
- Trung gian song song: still use Model 4, putting several variables in the box Mediator(s) M. PROCESS reports each indirect effect separately and the total indirect effect.
- Serial mediation (X → M1 → M2 → Y): use Model 6; the indirect effect through both variables is a1 × d21 × b2.
- SmartPLS: run Bootstrapping with 5.000 subsamples and read the table Specific indirect effects (coefficient, t, p and confidence interval) for each indirect path (Hair, Risher, Sarstedt & Ringle, 2019). The measurement model must pass CR, AVE and HTMT before reading the structural model.
Indirect effects are usually small, so a larger sample is needed for enough power; see the article how to calculate sample size. The module AutoFillForm SPSS research lets you declare paths, including paths through a mediator, and see path coefficients and p-values on the data; it doesn't replace the bootstrap confidence intervals of PROCESS or SmartPLS. Simulated data is only for testing the questionnaire and practising the workflow, never instead of real survey data.

Reporting the results and checklist
PROCESS Model 4 (Hayes, 2022) with 5.000 bootstrap samples showed that service quality positively affects satisfaction (a = 0,52; p < 0,001) and satisfaction positively affects loyalty controlling for service quality (b = 0,41; p < 0,001). The indirect effect of service quality on loyalty through satisfaction is significant (ab = 0,213; BootSE = 0,038; 95% CI [0,142; 0,291]). The direct effect remains significant (c′ = 0,18; p = 0,012) with the same sign as the indirect effect, so this is complementary mediation (Zhao et al., 2010). Total effect c = 0,393 (p < 0,001).
| Path | Coefficient | SE | p or 95% CI | Conclusion |
|---|---|---|---|---|
| a: CLDV → HL | 0,520 | 0,049 | p < 0,001 | Significant |
| b: HL → TT | 0,410 | 0,055 | p < 0,001 | Significant |
| c′: CLDV → TT (direct) | 0,180 | 0,071 | p = 0,012 | Significant |
| ab: CLDV → HL → TT | 0,213 | 0,038 (BootSE) | [0,142; 0,291] | Significant |
| c: total effect | 0,393 | 0,068 | p < 0,001 | Significant |
- There is a theory explaining why X → M → Y, not just the data.
- The X, M and Y scales have passed reliability and validity; construct mean scores are used.
- ab tested with 5.000 bootstrap samples, 95% percentile CI; seed recorded.
- A significant c is not required before testing mediation.
- a, b, c′, c and ab reported with SE, p or confidence intervals, and c = c′ + ab checked.
- Classified per Zhao et al. (2010) instead of "full/partial" labels.
- The causal limits of cross-sectional data acknowledged in the limitations.
Frequently asked questions
References
- Baron, R. M., & Kenny, D. A. (1986). The moderator–mediator variable distinction in social psychological research: Conceptual, strategic, and statistical considerations. Journal of Personality and Social Psychology, 51(6), 1173–1182.
- Hair, J. F., Risher, J. J., Sarstedt, M., & Ringle, C. M. (2019). When to use and how to report the results of PLS-SEM. European Business Review, 31(1), 2–24.
- Hayes, A. F. (2022). Introduction to mediation, moderation, and conditional process analysis: A regression-based approach (3rd ed.). The Guilford Press.
- Preacher, K. J., & Hayes, A. F. (2008). Asymptotic and resampling strategies for assessing and comparing indirect effects in multiple mediator models. Behavior Research Methods, 40(3), 879–891.
- Sobel, M. E. (1982). Asymptotic confidence intervals for indirect effects in structural equation models. Sociological Methodology, 13, 290–312.
- Zhao, X., Lynch, J. G., & Chen, Q. (2010). Reconsidering Baron and Kenny: Myths and truths about mediation analysis. Journal of Consumer Research, 37(2), 197–206.
The thresholds in this article are common conventions in the sources above. Check them against your supervisor's or target journal's requirements.