Researchers at University College Cork, led by Professor Yvonne Nolan, have found key biological reasons why exercise can help protect your mental health, even if you eat a typical Western diet high in fat and sugar. Your diet plays a huge role in keeping your brain healthy. Studies have shown that eating processed foods can increase your chances of developing memory and thinking issues. However, this one habit can help you keep these issues at bay, according to researchers. The study, published in the journal Brain Medicine, shows that regular running can reduce symptoms similar to depression that are often caused by unhealthy eating. These protective effects involve changes to your gut and hormones. Can You Eat Junk If You Exercise Enough? To figure out how diet and exercise influence the brain, the researchers studied adult male rats for seven and a half weeks. One group of rats ate a standard healthy diet, while the other group ate a rotating "cafeteria diet" of high-fat, high-sugar foods (like ultra-processed meals). In both diet groups, half of the animals were given a running wheel to exercise freely. This setup allowed the team to clearly see the separate and combined effects of the poor diet and physical activity on the animals' mood and brain. The main finding was positive Voluntary running had an antidepressant-like effect on the rats, even those eating the unhealthy cafeteria diet. This suggests that getting regular physical activity can be helpful for a person's mood, even if they struggle to completely change their eating habits. Mood and Memory While the unhealthy diet didn't severely harm the rats' learning or memory skills, exercise slightly improved their ability to navigate. The researchers also noticed mild anti-anxiety effects from exercise that occurred regardless of what the animals were eating. Can Your Diet Affect Your Mental Capacity? The high-fat, high-sugar diet severely messed up the chemicals produced in the gut (called metabolites). The researchers analyzed the contents of the caecum (a part of the large intestine) and found that the unhealthy diet affected 100 out of 175 chemical compounds they checked. Exercise helped to restore the balance, particularly increasing three metabolites—anserine, indole-3-carboxylate, and deoxyinosine—that are known to be important for regulating mood. The study did find one complex finding related to brain growth. In rats that ate the standard, healthy food, exercise strongly boosted adult hippocampal neurogenesis (the creation of new brain cells in the hippocampus, the area linked to memory and emotion). However, the cafeteria diet prevented this usual exercise-induced increase in new brain cells. This suggests that while exercise helps mood regardless of diet, a poor diet might actually stop the brain from fully gaining some of the deepest, cellular-level benefits of physical activity.Is Exercise Good For Your Mental Health? This research has important real-world meaning. As an accompanying editorial noted, the fact that "exercise has an antidepressant-like effect in the wrong dietary context... is good news" for people who find it very hard to switch to a perfect diet. The findings give biological proof that exercise can be an effective tool for improving mental well-being even when facing the challenges of modern, processed foods. Future research will need to study women and explore longer periods of exercise, but this study provides a strong foundation for using lifestyle changes to support mood and brain function.