This study investigated the association between social anxiety and sleep quality and further explored the potential mediating role of internet addiction in depressed adolescents. This study included 440 Chinese depressed adolescents (mean age = 15.0 years, SD = 2.0). Participants completed questionnaires, including Social Avoidance and Social Distress Scale, Internet Addiction Test, and Pittsburgh Sleep Quality Index. A structural equation model was used to analyze the association between social anxiety and sleep quality, with internet addiction as a mediator. Gender differences were examined by multi-group analysis. Among participants, 61.8% reported poor sleep quality. The sleep quality was significantly different on the level of gender (p = 0.016), education level (p = 0.043), and family history (p = 0.002). Sleep quality was positively associated with social anxiety (p < 0.001) and internet addiction (p < 0.001). Furthermore, internet addiction partially mediated the relationship between social anxiety and sleep quality, and the mediation effect ratio was 16.1% (p < 0.001). Finally, no significant differences were found in this mechanism. We concluded that both social anxiety and internet addiction were risk factors for depressed adolescents' poor sleep quality. Social anxiety further affected sleep quality through internet addiction.