BACKGROUND: Mexico declared an obesity epidemic in 2000, and in response, became an early adopter of public policies in the form of natural experiments, which have not been evaluated for their effect on high BMI. We focus on children younger than 5 years due to the long-term outcomes of childhood obesity. METHODS: We used the Global Burden of Disease data to evaluate time trends in high BMI, defined as being overweight or obese based on the International Obesity Task Force standards, between 1990 and 2019. Marginalisation and poverty estimates from Mexico's Government were used to identify differences in socioeconomic groups. The time variable reflects the introduction of policies between 2006 and 2011. Our hypothesis was that poverty and marginalisation modify the effects of public policies. We tested for the change in prevalence of high BMI over time using Wald-type tests, correcting for the effect of repeated measures. We stratified the sample by gender, marginalisation index, and households under the poverty line. Ethics approval was not required. FINDINGS: Between 1990 and 2019, high BMI in children younger than 5 years increased from 23·5% (95% uncertainty interval 38·6-14·3) to 30·2% (46·0-20·4). After a period of sustained increase to 28·7% (44·8-18·6) in 2005, high BMI decreased to 27·3% (42·4-17·4; p<0·001) in 2011. Afterwards, high BMI increased constantly. We found an average gender gap of 12·2%, with a higher rate in males, in 2006, which remained constant. With respect to marginalisation and poverty, we observed a reduction in high BMI across all strata, except for the uppermost quintile of marginalisation in which high BMI remained flat. INTERPRETATION: The epidemic affected groups across different socioeconomic levels, thus weakening economic explanations for the decrease in high BMI, while gender gaps point to behavioural explanations of consumption. The observed patterns warrant investigation through more granular data and structural models to isolate the effect of the policy from secular trends in the population, including other age groups. FUNDING: Tecnológico de Monterrey Challenge-Based Research Funding Program.