HIV-related stigma, and particularly perceived stigma, has a negative impact across the HIV care continuum. This study adds to our understanding of stigma by assessing how perceived stigma varies from one context to another and how such differences are associated with the location where individuals would prefer an HIV test. We used self-administered questionnaire data (n = 378) obtained from a convenience sample of students (18 years and older) attending a tertiary education institution in Durban, South Africa. Perceived stigma in the university environment was compared to perceived stigma in the home community environment. Multiple logistic regression analysis tested whether a higher level of perceived stigma in one setting was associated with a preference for HIV testing in the other setting. While levels of symbolic stigma and discrimination were low, a large proportion of the sample perceived that people living with HIV experience some form of stigmatisation in the home community and university environments (47% vs 41%, p = 0.09). A total of 31% reported less perceived stigma in the university environment. Students who perceived less stigma in the university environment were significantly more likely to report a preference for HIV testing at the university clinic rather than at a clinic in their community (aOR: 2.03; p < 0.01). Perceptions common across settings that people living with HIV experience stigmatisation are of great concern, especially for efforts to increase demand for HIV testing among young people. Results suggest that HIV-testing services in environments perceived to be less stigmatising than home communities could provide preferred alternatives for HIV testing.