BackgroundResearch has suggested an association between lower socioeconomic status (SES) and unhealthy dietary habits. However, differences in the effects of different SES indicators and age remain unclear. The current study addressed this research gap by investigating the relationship between SES and unhealthy dietary habits, specifically focusing on educational attainment and subjective financial status (SFS) among varied age groups.MethodsData were derived from a mail survey of 8,464 people living in a suburb of Tokyo, Japan. Participants were classified into three age groups (20–39 years: young adults; 40–64 years: middle-aged adults; and 65–97 years: older adults). SES was assessed based on individual educational attainment and SFS. Unhealthy dietary habits were defined as skipping breakfast and a low frequency of balanced meal consumption. Participants were asked how often they ate breakfast, and those who did not respond “every day” were categorized as “breakfast skippers.” Low frequency of balanced meal consumption was defined as eating a meal that included a staple meal, main dish, and side dishes at least twice a day for less than five days per week. Poisson regression analyses with robust variance adjusted for potential covariates were used to determine the interactive effects of educational attainment and SFS on unhealthy dietary habits.ResultsIndividuals with lower educational attainment across all age groups skipped breakfast more frequently compared to those with higher educational attainment. For older adults, poor SFS was associated with skipping breakfast. Young adults with poor SFS and middle-aged adults with lower educational attainment tended to eat less balanced meals. In addition, an interaction effect was found in older adults, where those with lower education despite good SFS and those with poor SFS despite higher education were at a greater risk of falling into unhealthy diet.ConclusionsThe findings suggested that different SES indicators affect healthy dietary habits in different generations, and therefore, health policies should consider the potential influence of different SES on promoting healthier dietary habits.Supplementary InformationThe online version contains supplementary material available at 10.1186/s12889-023-16131-7.