Childhood adversity (CA) has a substantial correlation with mental health problems. Keeping a healthy lifestyle is essential for mental health interventions; it is unclear, however, how healthy lifestyle affect the relationship between CA and persistent mental health problems. This longitudinal study (n=1112, 54.5% male) collected the data on CA (measured through three dimensions: threat, deprivation and unpredictability), mental health problems, and lifestyle factors. Group-based multi-trajectory modeling (GBMTM) was utilized to estimate trajectories for three mental health problems (i.e., depression, ADHD and overanxiety). Close friendships, regular physical activity, appropriate sleep duration, shorter screen time, and healthy eating were combined to establish a healthy lifestyle score (which ranges from 0 to 5). Higher scores indicated a healthier lifestyle. Three trajectories of mental health problems were identified: persistently low risk (24.9%), persistently medium-high risk (50.0%), and persistently high risk (25.1%). Multinomial logistic regression showed that high adversity (high-threat: β=2.01, P<0.001; high-deprivation: β=1.03, P<0.001; high-unpredictability: β=0.83, P=0.001; high-overall adversity: β=1.64, P<0.001) resulted in a persistently high risk of mental health problems; these outcomes were maintained after robust control for covariates. Further lifestyle stratification, null associations were observed among children with a healthy lifestyle, irrespective of their gender; however, after controlling for covariates, the above associations remained relatively stable only among boys. The generalizability of our findings is restricted by 1) limited racial diversity and 2) missing data. This finding underscores the benefits of promoting a healthy lifestyle in children to prevent persistent mental health problems caused by CA.