Background Early-life exposure to famine may influence the occurrence of chronic diseases and aging in midlife among those exposed. This study aims to explore the relationship between exposure to the Chinese Great Famine and aging in middle-aged individuals. Methods Participants born in 1963–1965 (unexposed), 1959–1961 (in utero exposure), and 1955–1957 (childhood exposure) from the Kailuan Study were included. Their biological age at 2010, 2014, and 2018 was investigated, and age acceleration (biological age minus actual age) was calculated to assess aging. Logistic regression analysis was employed to describe the relationship between famine exposure and the aging risk. Subgroup and sensitivity analysis were conducted to explore differences and stability in this relationship among different groups. Results A total of 17,543 participants were included in this study. Among them, 12,762 (72.7%) were male, and 4,781 (27.3%) were female, with 2,543 participants experiencing aging events. Compared to unexposed participants, those exposed during childhood and in utero exhibited a 1.69-fold (OR = 1.69, 95%CI: 1.53–1.87) and 1.22-fold (OR = 1.22, 95%CI: 1.08–1.37) increased risk of aging. Subgroup analysis revealed an interaction with income (P for interaction = 0.008), and additional interaction analysis suggested that increasing income could partially mitigate the detrimental effects of early-life famine exposure. Furthermore, experiencing famine in severely affected regions exacerbated the risk of aging (OR = 1.41, 95%CI: 1.21–1.63). Conclusion Exposure to famine in utero or during childhood may elevate the risk of midlife aging among exposed individuals, and these relationships are influenced by the severity of famine exposure. Increasing income may also help mitigate these effects.Trial registration: Kailuan study, ChiCTRTNRC11001489. Registered July 19, 2015 Retrospectively registered, https//www.chictr.org.cn/showprojEN.html?proj=8050&u_atoken=af46a0dee8d73f320bb5459ab7bbcfa9&u_asig=1a0c381017255295896468605e00cf .