Difference-in-differences compares an outcome before and after a policy change for an affected group, then subtracts the change measured in an unaffected comparison group. If resignations rise at a company imposing office attendance but stay stable at similar companies, the gap between those changes can help estimate the policy's effect.

The central assumption is that, without the policy, the groups would have followed comparable trends. Researchers often examine several periods before the event to test whether those trends looked parallel. Similar levels at one point in time are not enough if the groups were already moving in different directions.

The estimate can be distorted by another change occurring at the same time, such as layoffs, a compensation redesign or a local hiring shock. Differences in employee composition, anticipation of a policy and uneven treatment dates also require attention. Modern analyses may use methods tailored to staggered rollouts.

Look for pre-policy trends, a credible comparison group and uncertainty intervals around the estimated effect. A difference-in-differences result is stronger evidence than a simple before-and-after chart, but it is still conditional on assumptions that researchers must defend.