Maternal gestational diabetes mellitus (GDM) is considered to be an important factor that epigenetically predisposes offspring to metabolic and cardiovascular diseases. However, the mechanisms of how intrauterine hyperglycaemia affects offspring have not been thoroughly studied. The mammalian tribbles homologue 1 (TRIB1) gene is associated with plasma lipid concentrations and coronary artery disease (CAD). Our aim was to study the effect of GDM and its treatment terms on the level of TRIB1 gene expression in human umbilical vein endothelial cells (HUVECs) of newborns from women with and without GDM. The study included 50 women with GDM and 25 women without GDM (control group). Women with GDM were divided into three groups according to their gestational age when the treatment of GDM started: 24–28 weeks (GDM1, N = 16), 29–32 weeks (GDM2, N = 25) and >34 weeks (GDM3, N = 9). The levels of TRIB1 gene expression in GDM3, GDM2, GDM1 and control groups were 2.8 ± 1.1, 4.2 ± 2.4, 6.0 ± 3.4 and 8.1 ± 6.1, respectively (p = 0.001). After comparison in pairs the difference was significant for the following pairs: GDM2–control (p = 0.004), GDM3–control (p = 0.002), GDM1–GDM3 (p = 0.012). Notably, if treatment had been started before the 28th week of gestation, the difference in TRIB1 gene expression in HUVECs was not significant (p = 0.320 for comparison between GDM1 and control groups). Our findings support the hypothesis that TRIB1 gene expression in HUVECs depends on the duration of intrauterine exposure to hyperglycaemia.