Summary In forest communities, the Janzen–Connell (J‐C) hypothesis proposes that species diversity is maintained by non‐competitive distance‐ and/or density‐dependent seedling mortality caused by host‐specific natural enemies. However, the effects of pathogen associations from nearby conspecifics versus heterospecifics remain unknown in spatially heterogeneous light environments. Seeds of hardwood species Cornus controversa (Cornus) and Prunus grayana (Prunus) were sown beneath 6–7 Cornus and Prunus adults in both the forest understory (FU) and in gaps (Gap) created by felling all woody vegetation near the focal adults. Seedling growth, mortality, killing agents (e.g. pathogens that cause damping‐off and leaf diseases), and root infection by arbuscular mycorrhizal fungi (AMF) were investigated. We found strong habitat effects on the expression of soil fungi beneath both tree species. Seedling mortality caused by soil‐borne damping‐off pathogens was greater in FU than in Gap, and AMF infection, which enhanced relative seedling growth rate, was greater in Gap than in FU. Seedling mortality caused by damping‐off pathogens did not differ between Cornus and Prunus seedlings beneath the adults of conspecific or heterospecific adults in both FU and Gap, suggesting little distance‐dependence or host preference in the fungus. Beneath the adults of Cornus and Prunus, the most prevalent leaf diseases were zonate leaf blight and angular leaf spot caused by the airborne pathogenic fungi Haradamyces foliicola and Phaeoisariopsis pruni‐grayanae, respectively. Although these pathogens attacked the seedlings of both species, conspecific seedlings (i.e. home) showed more severe leaf damage, earlier leaf shedding and/or less defensive behaviour (cell wall defence) relative to heterospecific seedlings (i.e. away), suggesting negative distance‐dependent attack (i.e. host preference) for these leaf diseases. As a result, greater seedling mortality was observed for conspecific seedlings under both FU and Gap treatments. Synthesis. In the temperate forest, the J‐C hypothesis is largely mediated through the strong negative influence of airborne leaf diseases rather than through soil‐borne damping‐off pathogens. We found that airborne diseases demonstrated distance‐dependent host preferences, which led to greater conspecific seedling damage regardless of environmental light conditions.