Abstract
BACKGROUND: Sleep is a fundamental biological process essential for cognitive performance, emotional regulation, and academic functioning. Medical students are particularly vulnerable to poor sleep quality due to demanding coursework, irregular schedules, and heightened psychological stress. Although global studies have documented a high prevalence of sleep disturbances in this group, evidence from low-resource educational settings such as Somalia remains limited. This study aimed to determine the prevalence of poor sleep quality, identify associated factors, and evaluate whether depressive symptoms mediate the relationship between social support and sleep quality among medical students in Mogadishu. METHODS: A multicenter cross-sectional study was conducted between July and August 2025 among 272 medical students from four universities in Mogadishu. Data were collected electronically using a structured questionnaire on sociodemographic, academic, behavioral, and psychosocial characteristics, along with validated instruments: the Pittsburgh Sleep Quality Index (PSQI), the Patient Health Questionnaire-9 (PHQ-9), and the Oslo Social Support Scale-3 (OSSS-3). Descriptive statistics summarized participant characteristics, while logistic regression identified independent predictors of poor sleep quality. Spearman’s rank-order correlations and Hayes’ PROCESS macro (Model 4) were used to explore associations and mediation effects. Statistical significance was set at p < 0.05. RESULTS: The prevalence of poor sleep quality among medical students was 41.5% (95% CI: 35.6–47.6). Poor sleep predictors included nighttime screen use (AOR = 2.71, 95% CI: 1.24–5.95), stressful life events (AOR = 2.05, 95% CI: 1.12–3.77), physical inactivity (AOR = 2.70, 95% CI: 1.20–6.10), depressive symptoms (AOR = 2.73, 95% CI: 1.51–4.91), and poor social support (AOR = 2.30, 95% CI: 1.04–5.10). Mediation analysis indicated that depressive symptoms fully mediated the association between social support and sleep quality, implying that lower social support may contribute to poorer sleep primarily through its influence on depressive symptomatology. CONCLUSION: Poor sleep quality affects more than two-fifths of medical students in Mogadishu and is linked to key behavioral and psychosocial factors relevant to student well-being. Institutional strategies promoting healthy digital habits, regular physical activity, and psychosocial support are needed to enhance student well-being and educational success.