This study aimed to examine associations between plasma sex-related hormones with bone mineral density (BMD) and risks of osteoporosis or osteopenia in men and postmenopausal women patients with type 2 diabetes mellitus (T2DM). Baseline information on an ongoing cohort of 149 men and 102 postmenopausal women with T2DM in Xiamen, China were analyzed. Plasma estradiol (E2), total testosterone (T), follicle-stimulating hormone (FSH), luteinizing hormone (LH) and prolactin (PRL) were measured. BMD of lumbar spine (L2-4), femoral neck (FN) and total hip (TH) were determined by dual-energy X-ray absorptiometry (DXA). Osteoporosis or osteopenia was defined as the minimum T-scores of BMD of these three different sites of -1.0 or below. T2DM patients with osteoporosis/osteopenia (66.4% in men and 79.4% in postmenopausal women), compared to those without, showed significantly decreased level of E2 (75.3±28.9 vs. 107.8±25.9pmol/L and 18.4 (18.4-29.5) vs. 22.8 (18.4-40.5) pmol/L for men and postmenopausal women, respectively, both p-values <0.05), but not other sex-related hormones (including T, FSH, LH, or PRL). For all T2DM patients together and men separately, multivariable linear regression and logistic regression analyses showed that higher E2 levels were significantly associated with higher BMD T-scores in L2-4, FN, TH and minimum of these three different sites, lower 10-year probability of major osteoporotic fractures (MOF) and hip fractures (HFs) estimated by Fracture Risk Assessment Tool score, as well as decreased risk of osteoporosis/osteopenia. As for postmenopausal women T2DM patients, E2 level was positively associated with BMD T-scores in L2-4 and minimum of three different sites but was not independently associated with risk of osteoporosis/osteopenia. Higher plasma E2 was significantly associated with increased BMD and lower risk of osteoporosis or osteopenia in T2DM patients, especially for men. Screening of BMD and estradiol levels as well as evaluating risks of osteoporosis/osteopenia are important for T2DM patients.