BACKGROUND: Evidence on active commuting and heart failure (HF) under levels of air pollution exposure is limited, and little is known on the potential mediation roles of inflammation. The objective of this study was to investigate the association between active commuting and HF, as well as to ascertain whether air pollution may influence this relationship. METHODS: This prospective study included 241,786 participants without HF at baseline in UK Biobank. The commuting mode was recorded using questionnaire. We examined long-term exposure to air pollution, including particulate matter with an aerodynamic diameter smaller than 2.5 μm (PM RESULTS: A median follow-up period of 13.7 years yielded 4485 incident cases of HF. Compared with non-active commuting, both cycling (HR = 0.66, 95%CI: 0.57-0.76) and walking mode (HR = 0.86, 95%CI: 0.78-0.94) were found to be associated with the reduced risk of HF, following the full adjustment for covariates, including PM CONCLUSIONS: For those residing in regions with relatively elevated air pollution levels, active commuting may still be a viable strategy for the prevention of HF.