Early labour market exit of large birth cohorts will put pressure on the social security systems of many European countries, especially Germany. Despite political efforts, many people retire before the statutory retirement age. A well-known predictor of retirement is health, which, in turn, is influenced by psychosocial working conditions such as work-related stress. This study examined whether work stress is associated with early labour market exit. In addition, we investigated whether health mediates this association. Survey data of the German Cohort Study on Work, Age, Health and Work Participation (lidA study) were linked to register data from the Federal Employment Agency, from which information on labour market exit was obtained (n= 3636). During a 6-year follow-up period, Cox proportional hazard models were used to investigate the influence of work-related stress and health on early labour market exit, adjusting for sex, age, education, occupational status, income and supervisor behaviour. Work-related stress was measured by effort–reward imbalance (ERI). Additionally, a mediation analysis was conducted to investigate a possible mediation of the association between ERI and early labour market exit by self-rated health. Higher work-related stress increased the likelihood of early labour market exit (HR 1.86; 95% CI 1.19–2.92). However, when including health in the Cox regression, the significant effect of work-related stress disappeared. Poor health was a risk factor for early labour market exit (HR 1.49; 95% CI 1.26–1.76) independent of all confounders. The results of the mediation analysis showed that self-rated health mediated the association between ERI and early labour market exit. The balance between effort and reward at work plays a major role in improving the self-rated health of workers. Interventions that reduce work-related stress can help to improve health and thus to maintain older employees in the German labour market.Supplementary InformationThe online version contains supplementary material available at 10.1007/s10433-023-00778-7.