BackgroundAcquired immunodeficiency syndrome (AIDS) is a global pandemic caused by human immunodeficiency virus (HIV), which is transmitted through human behaviors, such as sexual intercourse, intravenous drug injection, and blood transfusion. Rare studies have focused on the evaluation of the effects of culture, society, and HIV-related policies in adjusting people's HIV-related behaviors, i.e., ways of HIV transmission.MethodsBy taking the new HIV infections in Hubei Province each year from 1995 to 2020 as the sample, our study used the Hierarchical Age-Period-Cohort (HAPC) model to analyze the effects of age, period, and cohort on the trends of ways of HIV transmission.ResultsFrom 1995 to 2020, the number of new HIV infections in Hubei presented a general upward trend. A total of 34,636 HIV infections were reported during this period. According to the statistics of the new HIV infections in Hubei Province between 1995 and 2020, there is a negative correlation between age (−0.099, p < 0.001), squared age (−0.002, p < 0.001), and the rate of blood transmission. While there is a positive correlation between age (0.143, p < 0.001), squared age (0.002, p < 0.001), and the rate of HIV infection through sexual transmission. The significant period and cohort effects on ways of HIV transmission were also observed in the Chinese population.ConclusionSexual and blood transmission are the two main ways of HIV infection in China and Hubei. The trend of blood transmission is in accordance with the wave of blood trade in the early 1990s in China. The trend of sexual transmission indicates an increasing need to promote safer sexual behavior among the older population and later generations and design more tailored, innovative, and diverse HIV prevention strategies, especially for the high-risk groups.