Objective: To investigate the effects of Zolpidem combined with Shugan Jieyu capsules on sleep quality and daytime cognitive function in patients with insomnia disorder with depressive symptoms. Methods: Randomized controlled trial. Sixty patients with insomnia disorder with depressive symptoms prospectively recruited from Nanfang Hospital, Southern Medical University from March to October 2023, were randomly divided into an experimental group and a control group, with 30 patients in each group. The experimental group received oral administration of Zolpidem 10 mg/d and Shugan Jieyu capsules 0.72 g/d for 8 weeks, while the control group received oral administration of Zolpidem 10 mg/d and placebo 0.72 g/d for 8 weeks. Repeated-measures analysis of variance was used to assess changes in the insomnia severity index (ISI), Pittsburgh sleep quality index (PSQI), Epworth sleepiness scale (ESS), patient health questionnaire-9 (PHQ-9), working memory (low-load 1-back task, high-load 2-back task), and polysomnography at baseline, 4 weeks, and 8 weeks between the two groups. Result: A total of 59 patients completed the trial, with 30 in the experimental group [14 males, age (28.5±7.8) years] and 29 in the control group [9 males, age (26.5±5.3) years]. There were no statistically significant differences in age, gender, education level, body mass index, illness duration, apnea-hypopnea index (AHI) and periodic limb movement index (PLMI) between the two groups (all P>0.05). At week 4 and 8 of treatment, the ISI scores of the experimental group [(10.6±5.9) and (8.7±6.7), respectively] and the control group [(11.7±5.1) and (10.6±5.1), respectively] were lower than the baseline values (experimental group: 18.7±4.4) and (control group: 18.9±3.6). In addition, at weeks 4 and 8 of treatment, both groups showed lower PSQI scores, ESS scores, and PHQ-9 scores than baseline and higher N2 sleep stage, sleep efficiency, and accuracy of the high-load cognitive 2-back task than baseline values (all P<0.05). Among them, there was an interaction between the time and the group of high-load cognitive 2-back tasks (the improvement rates of the experimental group at week 4 and 8 were 9.4%±13.2% and 5.7%±13.8% respectively, and the improvement rates in the control group at week 4 and 8 were 20.1%±19.8% and 5.5%±8.7% respectively) (all P<0.05). There were no significant differences between the two groups in terms of ISI score, PSQI score, ESS score, PHQ-9 score, N2 sleep stage, sleep efficiency, and accuracy of 2-back tasks on high-load cognitive tasks at week 4 and 8 of treatment (all P>0.05). Conclusion: Based on comparable improvements achieved in sleep quality and depressive symptoms, the combination of Zolpidem and Shugan Jieyu capsules showed further improvement in the recovery pattern of high-load working memory during the day.