The presence of Lactobacillus paragasseri/gasseri (aOR: 3.12, 95% CI: 1.24-7.84), Streptococcus (aOR: 3.58, 95% CI: 1.68-7.65), or Proteobacteria (aOR: 3.39, 95% CI: 1.55-7.39) was associated with an increased risk of sPTB in the non-GDM group (P < 0.05). This evidence concerns the gene SPTB and gestational diabetes.