BACKGROUND: Diabetic retinopathy (DR) not only leads to visual impairment but also increases the risk of death in type 2 diabetes patients. This study aimed to construct a nomogram to assess the risk of all-cause mortality in patients with DR. METHODS: This cross-sectional study included 1004 patients from the National Health and Nutrition Examination Survey database (NHANES) between 1999-2018. Participants were randomized in a 7:3 ratio into a training set and a test set. We selected predictors by LASSO regression and multifactorial Cox proportional risk regression analysis and constructed nomograms, guided by established clinical guidelines and expert consensus as the gold standard. We used the concordance index (C-index), receiver operating characteristic curve (ROC), calibration curve, and decision curve analysis (DCA) to evaluate the nomogram's discriminative power, calibration quality, and clinical use. RESULTS: The training and test sets consisted of 703 and 301 participants with a median age of 64 and 63 years, respectively. The study identified seven predictors, including age, marital status, congestive heart failure (CHF), coronary heart disease (CHD), stroke, creatinine level, and taking insulin. The C-index of the nomogram model constructed from the training set was 0.738 (95% CI: 0.704-0.771), while the C-index of the test set was 0.716 (95% CI: 0.663-0.768). In the training set, the model's AUC values for predicting all-cause mortality risk at 3 years, 5 years, and 10 years were 0.739, 0.765, and 0.808, respectively. In the test set, these AUC values were 0.737, 0.717, and 0.732, respectively. The ROC curve, calibration curve, and DCA curve all demonstrated excellent predictive performance, confirming the model's effectiveness and reliability in clinical applications. CONCLUSIONS: Our nomogram demonstrates high clinical predictive accuracy, enabling clinicians to effectively predict the overall mortality risk in patients with DR, thereby significantly improving their prognosis.