Mediator vs. Moderator Variables | Differences & Examples

A mediating variable (or mediator) explains the process through which two variables are related, while a moderating variable (or moderator) affects the strength and direction of that relationship.

Including mediators and moderators in your research helps you go beyond studying a simple relationship between two variables for a fuller picture of the real world. These variables are important to consider when studying complex correlational or causal relationships between variables.

What’s the difference?

You can think of a mediator as a go-between for two variables. For example, sleep quality (an independent variable) can affect academic achievement (a dependent variable) through the mediator of alertness. In a mediation relationship, you can draw an arrow from an independent variable to a mediator and then from the mediator to the dependent variable.

In contrast, a moderator is something that acts upon the relationship between two variables and changes its direction or strength. For example, mental health status may moderate the relationship between sleep quality and academic achievement: the relationship might be stronger for people without diagnosed mental health conditions than for people with them.

In a moderation relationship, you can draw an arrow from the moderator to the relationship between an independent and dependent variable.

Mediator and moderator variables

Mediating variables

A mediator is a way in which an independent variable impacts a dependent variable. It’s part of the causal pathway of an effect, and it tells you how or why an effect takes place.

If something is a mediator:

  1. It’s caused by the independent variable.
  2. It influences the dependent variable
  3. When it’s taken into account, the statistical correlation between the independent and dependent variables is higher than when it isn’t considered.

Mediation analysis is a way of statistically testing whether a variable is a mediator using linear regression analyses or ANOVAs.

In full mediation, a mediator fully explains the relationship between the independent and dependent variable: without the mediator in the model, there is no relationship.

In partial mediation, there is still a statistical relationship between the independent and dependent variable even when the mediator is taken out of a model: the mediator only partially explains the relationship.

Example: Mediator variables
In a study on socioeconomic status and reading ability in children, you hypothesize that parental education level is a mediator. This means that socioeconomic status affects reading ability mainly through its influence on parental education levels.

Example of a mediator variable

You use a descriptive research design for this study. After collecting data on each of these variables, you perform statistical analysis to check whether:

  1. Socioeconomic status predicts parental education levels,
  2. Parental education levels predicts child reading ability,
  3. The correlation between socioeconomic status and child reading ability is greater when parental education levels are taken into account in your model.

Here's why students love Scribbr's proofreading services

Discover proofreading & editing

Moderating variables

A moderator influences the level, direction, or presence of a relationship between variables. It shows you for whom, when, or under what circumstances a relationship will hold.

Moderators usually help you judge the external validity of your study by identifying the limitations of when the relationship between variables holds. For example, while social media use can predict levels of loneliness, this relationship may be stronger for adolescents than for older adults. Age is a moderator here.

Moderators can be:

  • Categorical variables such as ethnicity, race, religion, favorite colors, health status, or stimulus type,
  • Quantitative variables such as age, weight, height, income, or visual stimulus size.
Example: Moderator variables
In a study on work experience and salary, you hypothesize that:

  • years of work experience predicts salary, when controlling for relevant variables,
  • gender identity moderates the relationship between work experience and salary.

This means that the relationship between years of experience and salary would differ between men, women, and those who do not identify as men or women.

Example of a moderator variable

To test this statistically, you perform a multiple regression analysis for the data on work experience and salary, with gender identity added in the model. You compare the statistical significance of the model with and without gender identity included to determine whether it moderates the relationship between work experience and salary.

Frequently asked questions about mediators and moderators

What’s the difference between a mediator and a moderator?

A mediator variable explains the process through which two variables are related, while a moderator variable affects the strength and direction of that relationship.

What’s the difference between a confounder and a mediator?

A confounder is a third variable that affects variables of interest and makes them seem related when they are not. In contrast, a mediator is the mechanism of a relationship between two variables: it explains the process by which they are related.

Why should you include mediators and moderators in a study?

Including mediators and moderators in your research helps you go beyond studying a simple relationship between two variables for a fuller picture of the real world. They are important to consider when studying complex correlational or causal relationships.

Mediators are part of the causal pathway of an effect, and they tell you how or why an effect takes place. Moderators usually help you judge the external validity of your study by identifying the limitations of when the relationship between variables holds.

How can you tell if something is a mediator?

If something is a mediating variable:

  • It’s caused by the independent variable.
  • It influences the dependent variable
  • When it’s taken into account, the statistical correlation between the independent and dependent variables is higher than when it isn’t considered.

Sources in this article

We strongly encourage students to use sources in their work. You can cite our article (APA Style) or take a deep dive into the articles below.

This Scribbr article

Bhandari, P. (July 21, 2022). Mediator vs. Moderator Variables | Differences & Examples. Scribbr. Retrieved October 19, 2022, from https://www.scribbr.com/methodology/mediator-vs-moderator/

Is this article helpful?
Pritha Bhandari

Pritha has an academic background in English, psychology and cognitive neuroscience. As an interdisciplinary researcher, she enjoys writing articles explaining tricky research concepts for students and academics.