INTRODUCTION: Lack of knowledge about the spread of human immunodeficiency virus (HIV) is the primary reason behind the discriminatory attitudes of nurses towards people living with HIV and acquired immunodeficiency syndrome (AIDS). Therefore, this study aimed to investigate nurses' knowledge and attitudes towards HIV/AIDS. METHODOLOGY: This descriptive cross-sectional study involved 188 nurses working in two major public hospitals in Erbil city. The study participants were selected using a census method. The questionnaires were designed to specifically evaluate the nurses' knowledge and attitudes towards HIV/AIDS. The data were analyzed using IBM SPSS version 26. RESULTS: The mean score of knowledge about HIV/AIDS was 65.60 ± 9.79, which was at a moderate level. The mean score of attitudes toward HIV/AIDS was 36.64 ± 10.34, which was at a poor level. There was a low negative correlation between knowledge and attitude towards HIV/AIDS (p = 0.009). Married individuals and Muslims had higher knowledge, while participants aged over 30 years had a more positive attitude. Single individuals, urban residents, and Christians had more positive attitudes compared to their counterparts. CONCLUSIONS: Lack of knowledge of HIV/AIDS and its transmission can impede the care process, while a positive attitude towards patients with AIDS is essential for providing compassionate care. Therefore, it is crucial to explore effective strategies that can enhance healthcare providers' knowledge and attitudes towards patients with AIDS. This approach can improve the quality of care provided to this vulnerable population.