The current study examines the mediating roles of self-efficacy and sleep disturbance and the moderating role of gender in the association between the duration of youth/parent communication on depression and anxiety during the COVID-19 isolation period in China. We used the self-designed demographic variable questionnaire, General Self-Efficacy Scale, the Pittsburgh Sleep Quality Index, the Self-Rating Depression Scale, and the Self-Rating Anxiety Scale with 1,772 youths aged 15–24 from 26 provinces in China during the COVID-19 lockdown. We performed demographic variable analysis, correlation analysis, mediation analysis, and moderated analysis. The duration of daily communication with parents was significantly positively correlated with self-efficacy and significantly negatively correlated with sleep disturbance, depression, and anxiety. The chain mediation analysis revealed that the duration of communication with parents directly affected depression and anxiety. Self-efficacy, sleep disturbance, and self-efficacy sleep disturbance had significant mediating and chain-mediating effects on the duration of communication with parents, depression, and anxiety. The interactions between sleep disturbance and gender (B = 0.35, 95% CI 0.06 to 0.64, p = .02 < .05) were significant. The duration of parent/youth communication directly affected depression and anxiety and indirectly affected depression and anxiety via the chain-mediating effect of self-efficacy and sleep disturbance. Gender moderates the relationships between sleep disturbance and depression.