Diabetic osteoporosis (DOP) is a diabetic complication associated with a significant disability rate. Liraglutide, a glucagon-like peptide-1 receptor agonist, is a promising and innovative drug for type 2 diabetes mellitus (T2DM), with potential therapeutic implications for bone disorders. This investigation examined the impact of liraglutide on osteoporosis in rats with T2DM and studied the influence of vitamin D receptor Bsm1 polymorphism on liraglutide-induced outcomes. Thirty rats were divided into control, T2DM induced by a combination of a high-fat diet and 25 mg/kg streptozotocin, and T2DM-liraglutide (T2DM treated with 0.4 mg/kg/day liraglutide) groups. After 8 weeks of liraglutide treatment, femurs and blood samples were obtained from all rats for subsequent investigations. Diabetes induced a remarkable rise in the serum levels of receptor activator of nuclear factor kappa B ligand (RANKL) and C-telopeptide of type I collagen (CTX-1) associated with a remarkable decline in osteocalcin and osteoprotegerin (OPG). Impaired bone architecture was also demonstrated by light and scanning electron microscopic study. The immune expression of OPG was down-regulated, while RANKL was up-regulated. Interestingly, the administration of liraglutide ameliorated the previous changes induced by diabetes mellitus. In conclusion, liraglutide can prevent DOP, mostly due to liraglutide's ability to increase bone growth, while inhibiting bone resorption.