Key Message
From a social-ecological perspective, this study delineates an association between adverse childhood experiences (ACEs), particularly those originating from the family, and diabetes among middle-aged and older Chinese. Interventions aimed at preventing and mitigating ACEs are essential for the early prevention of diabetes.