This study describes HIV disease burden and patterns of drug use before and during incarceration among detainees in Re-education-Through-Labour-Camps (RTLCs) in China. A cross-sectional survey of 576 men and 179 women from three RTLCs was conducted in Guangxi Province, China. Over three-quarters of study participants were detained due to drug-related offences. Over half of the women (n = 313, 54.3%) and two-thirds of men (n = 119, 66.5%) had been previously been incarcerated in a compulsory detoxification treatment centre (CDTC), and around one-third (men n = 159, 27.6%; women n = 50, 27.9%) in a RTLC. Of those surveyed, 49 men (8.5%) and one (0.6%) woman reported ever using drugs while in a CDTC and/or RTLC. Previous incarceration in CDTCs and RTLCs were associated with HIV infection among both male (OR = 2.15 [1.11-4.15]) and female (OR = 3.87 [1.86-9.04]) detainees. Being married/cohabiting with a partner (OR = 0.53, [0.30-0.93]) and being employed (OR = 0.46, [0.22-0.95]) were associated with a reduced odds of HIV infection among male detainees. A significant proportion of RTLC detainees had a history of drug use and a limited number of inmates had used illegal substances whilst in custody. Repeat incarcerations in CDTCs/RTLCs were associated with higher risks of HIV infection.