Adolescents and young adults (AYA) face multiple barriers to accessing healthcare services, which can interact, creating complex needs that often impact health behaviours, leading to increased vulnerability to HIV. We aimed to identify distinct AYA subgroups based on patterns of barriers to HIV testing services and assess the association between these barrier patterns and sexual behaviour, socio-demographics, and HIV status. Data were from Nigeria's AIDS Indicator and Impact Survey (NAIIS, 2018) and included 18,612 sexually active AYA aged 15-24 years who had never been tested for HIV and reported barriers to accessing HIV testing services. A Latent class analysis (LCA) model was built from 12 self-reported barrier types to identify distinct subgroups of AYA based on barrier patterns. Latent class regressions (LCR) were conducted to compare the socio-demographics, sexual behaviour, and HIV status across identified AYA subgroups. Sex behaviour characteristics include intergenerational sex, transactional sex, multiple sex partners, condom use, and knowledge of partner's HIV status. Our LCA model identified four distinct AYA subgroups termed 'low-risk perception' (n = 7,361; 39.5%), 'consent and proximity' (n = 5,163; 27.74%), 'testing site' (n = 4,996; 26.84%), and 'cost and logistics' (n = 1,092; 5.87%). Compared to adolescents and young adults (AYA) in the low-risk perception class, those in the consent and proximity class were more likely to report engaging in intergenerational sex (aOR 1.17, 95% CI 1.02-1.35), transactional sex (aOR 1.50, 95% CI 1.23-1.84), and have multiple sex partners (aOR 1.75, 95% CI 1.39-2.20), while being less likely to report condom use (aOR 0.79, 95% CI 0.63-0.99). AYA in the testing site class were more likely to report intergenerational sex (aOR 1.21, 95% CI 1.04-1.39) and transactional sex (aOR 1.53, 95% CI 1.26-1.85). AYA in the cost and logistics class were more likely to engage in transactional sex (aOR 2.12, 95% CI 1.58-2.84) and less likely to report condom use (aOR 0.58, 95% CI 0.34-0.98). There was no significant relationship between barrier subgroup membership and HIV status. However, being female, aged 15-24 years, married or cohabiting, residing in the Southsouth zone, and of Christian religion increased the likelihood of being HIV infected. Patterns of barriers to HIV testing are linked with differences in sexual behaviour and sociodemographic profiles among AYA, with the latter driving differences in HIV status. Findings can improve combination healthcare packages aimed at simultaneously addressing multiple barriers and determinants of vulnerability to HIV among AYA.