The association between opportunistic infection (OI) and anaemia among HIV-infected patients remains to be studied. We investigated the prevalence and risk factors of anaemia in hospitalised HIV-infected patients to reveal the association between OI and anaemia. We conducted a retrospective study of HIV-positive hospitalised patients from June 2016 to December 2017 in Mengchao Hepatobiliary Hospital of Fujian Medical University. Patients’ information on socio-demographic and clinical characteristics were carefully collected. The comparison of anaemia prevalence between groups was conducted with χ2 test. A logistic regression model was carried out to analyse the predictors of anaemia. The total prevalence of anaemia in hospitalised HIV-infected patients was 55.15%. The prevalence of mild, moderate and severe anaemia was 41.42%, 11.08% and 2.64%, respectively. Predictors independently associated with anaemia were: CD4 counts <50 cells/μl (odds ratio (OR): 6.376, 95% confidence interval (CI) = 1.916–21.215, P = 0.003), CD4 counts 50–199 cells/μl (OR: 6.303, 95% CI = 1.874–21.203, P = 0.003), co-infection with tuberculosis (TB) (OR: 2.703, 95% CI = 1.349–5.414, P = 0.005) or Penicillium marneffei (PM) (OR: 7.162, 95% CI = 3.147–15.299, P < 0.001). In Fujian, China, more than half inpatients with HIV were anaemic, but severe anaemia is infrequent. Lower CD4 counts, co-infection with TB or PM were independent risk factors for anaemia. Chinese HIV patients especially with TB, PM infection and low CD4 level should be routinely detected for anaemia to improve therapy.