The prevalence of human immunodeficiency type 1 (HIV-1) pretreatment drug resistance (PDR) in men who have sex with men (MSM) in Guangxi remains unclear, and its effect on antiretroviral therapy (ART) needs to be further studied. Individuals newly diagnosed with HIV in Guangxi from 2016 to 2020, which mainly included MSM and the heterosexual (HES) population, were recruited in this study. Pol sequences were sequenced to analyze PDR and construct a genetic network. The risk factors for PDR and the effect on ART were respectively analyzed. The PDR of MSM in Guangxi was 4.7% (34/716), consisting of nonnucleoside reverse transcriptase inhibitors (3.5%), protease inhibitors (0.8%), integrase strand transfer inhibitors (0.7%), and nucleoside reverse transcriptase inhibitors (0.4%), and lower than that of HES (9.3% [77/827]). The subtype was associated with PDR, and MSM was lower than HES (CRF01_AE: 3.0% vs 8.0%; CRF07_BC: 4.1% vs 7.2%). CRF55_01B (adjusted odds ratio [aOR], 3.35) was a risk factor for PDR in MSM, while CRF08_BC (aOR, 2.34) and older (aOR, 2.75) were risk factors for PDR in HES. Six of 18 (33.3%) PDR of MSM in the network connected to each other, lower than that of HES (61.1% [22/36]). CRF55_01B (aOR, 5.69) was a risk factor for PDR transmission in MSM, while CRF08_BC (aOR, 4.08) was a risk factor in HES. Pretreatment CD4+ T-cell count, age, infection route, and subtype were associated with recovery of CD4+ count and suppression of viral load. The prevalence of PDR was different between MSM and HES, which may be associated with subtype. Thus, the monitoring of subtype and PDR should be strengthened.