Maternal obesity plays a key role in the health trajectory of the offspring. Although research on this topic has largely focused on the potential of this condition to increase the risk for child obesity, it is becoming more and more evident that it can also significantly impact cognitive function and mental health. The mechanisms underlying these effects are starting to be elucidated and point to the placenta as a critical organ that may mediate changes in the response to stress, immune function and oxidative stress. Long-term effects of maternal obesity may rely upon epigenetic changes in selected genes that are involved in metabolic and trophic regulations of the brain. More recent evidence also indicates the gut microbiota as a potential mediator of these effects. Overall, understanding cause-effect relationships can allow the development of preventive measures that could rely upon dietary changes in the mother and the offspring. Addressing diets appears more feasible than developing new pharmacological targets and has the potential to affect the multiple interconnected physiological pathways engaged by these complex regulations, allowing prevention of both metabolic and mental disorders.