This study examined the association between height and the risk of Gestational Diabetes Mellitus (GDM), and whether this association was mediated or moderated by early pregnancy body mass index (BMI) and gestational weight gain (GWG) that are known independent risk factors for GDM. Data of a retrospective cohort of pregnant women (N = 1,945) were extracted from antenatal clinic cards. The cut-off values of height in relation to risk of GDM were identified using receiver operating characteristic analysis and four categories of height were derived: < 150 cm, 150–155 cm, 156–160 cm, and > 160cm. Mediation analysis was performed using the Preacher and Hayes bootstrapping method while the moderation effect was tested with multiple regression analysis with interaction terms. Although there was no mediation effect of BMI and GWG on the association between height and risk of GDM, both factors moderated this association with a significant association between shorter height and risk of GDM was observed in overweight / obese women (height < 150 cm: AOR = 1.41, 95% CI = 1.03–2.44; height 156–160 cm: AOR = 1.48, 95% CI = 1.03–2.14). Overweight / obese women with height < 150 cm and excessive GWG at the end of the second trimester (AOR = 2.25, 95% CI = 1.45–4.17) had significantly higher risk of GDM than those without these factors. Short stature (< 150 cm) was significantly associated with GDM risk among OW/OB women with excessive gestational weight gain at the end of second trimester. This finding underscores the importance of maintaining a healthy BMI during reproductive age and gaining weight in recommended range during pregnancy.