To evaluate the relationship between newly diagnosed diabetes or prediabetes and depressive symptoms among individuals with risk factors for diabetes in China. We also investigated the associations of depressive symptoms with pancreatic β-cell function and insulin resistance. We used cross-sectional data from the Shanghai High-Risk Diabetic Screen (SHiDS) project. Between 2014 and 2017, a total of 1728 participants were enrolled in this study and underwent an oral glucose tolerance test to screen for diabetes and prediabetes. Insulin resistance was evaluated using the homeostatic model assessment of insulin resistance and the modified Matsuda index. Pancreatic β-cell function was calculated using the homeostatic model assessment of β-cell function, Stumvoll first- and second-phase indexes. Elevated depressive symptoms were determined using the Patient Health Questionnaire-9 (PHQ-9 score ≥ 10). The prevalence of elevated depressive symptoms in the total study population was 4.8% (83 of 1728). Compared with the normal glucose tolerance group, individuals with newly diagnosed diabetes were less likely to have elevated depressive symptoms even after controlling for potential confounders [adjusted odds ratio (OR) 0.35, 95% confidence interval (CI) 0.18-0.68; P=0.002]. However, prediabetes was not associated with depressive symptoms. The odds for elevated depressive symptoms were increased in individuals with higher levels of the Stumvoll first-phase index. No association was observed between depressive symptoms and insulin resistance. Elevated depressive symptoms were less prevalent in Chinese individuals with newly diagnosed diabetes among a high-risk population for diabetes.