This literature review summarizes modern concepts of gestational diabetes mellitus as an independent risk factor for the development of long-term neuropsychiatric diseases in offspring and the mechanisms of their programming in this complication of pregnancy in the absence of the protective role of maternal melatonin as a consequence of chronodestruction. The article presents literature data on the composition of breast milk and the participation of its endogenous melatonin, microRNAs, long non-coding RNAs, stem cells, and microbiome in reprogramming epigenetic disorders as a result of adverse effects in the antenatal period, which helps to reduce the likelihood of developing neuropsychiatric pathology later in life. It is emphasized that breastfeeding during the first six months of life and later, along with complementary foods under the age of two years and older, is exclusively a physiological and unsurpassed method of preventing long-term consequences of impaired brain development in offspring with gestational diabetes mellitus.