Multiple studies have demonstrated the significant effects of physical exercise on brain plasticity, the enhancement of memory and cognition, and mood improvement. Although the beneficial impact of exercise on brain functions and mental health is well established, the exact mechanisms underlying this phenomenon are currently under thorough investigation. Several hypotheses have emerged suggesting various possible mechanisms, including the effects of hormones, neurotrophins, neurotransmitters, and more recently also other compounds such as lactate or irisin, which are released under the exercise circumstances and act both locally or/and on distant tissues, triggering systemic body reactions. Nevertheless, none of these actually explain the long-lasting effect of exercise, which can persist for years or even be passed on to subsequent generations. It is believed that these long-lasting effects are mediated through epigenetic modifications, influencing the expression of particular genes and the translation and modification of specific proteins. This review explores the impact of regular physical exercise on brain function and brain plasticity and the associated occurrence of epigenetic modifications. It examines how these changes contribute to the prevention and treatment of neuropsychiatric and neurological disorders, as well as their influence on the natural aging process and mental health.