Objectives: This study identifies the factors associated with the occurrence of adverse events in adults and elderly on antiretroviral therapy. Methods: This is a cross-sectional study carried out with adults and elderly patients, attended by the Specialized Assistance Service between September 2016 and August 2017. Adverse events were measured through self-reports collected in interviews, information collected in medical records, and changes identified in laboratory tests, with the degree of causality being assessed using the Naranjo Algorithm. Univariate analysis, with results expressed as odds ratio (OR) and their respective confidence intervals (CI 95%), was performed to estimate the association between sociodemographic, pharmacotherapeutic, and clinical characteristics (explanatory variables) with the occurrence of four or more adverse events to antiretroviral therapy (response variable). For multivariate analysis, multiple logistic regression was considered in order to verify the permanence or absence of associations previously found in the univariate analysis. Results: Prevalence of adverse events to antiretroviral therapy was 92.6%, with the median of adverse events being four (IQR 25%: 2 ; IQR 75%: 5) and two (IQR 25%: 2 ; IQR 75%: 4), respectively, among adults and elderly (p <0.05). Additionally, 340 adverse events were identified, among which nightmares (15.0%) and vertigo (13.5%) were the most frequent. Most of the adverse events identified were classified as possible (96.2% / n = 327). In the initial univariate analysis, factors such receipt of guidance on adverse events and age were associated with a higher occurrence of adverse events to antiretroviral therapy. Contrary to expectations, the elderly were considered less susceptible to have adverse events when compared to adults (OR = 0.363; CI 95% = 0.164-0.801). However, the final multivariate analysis model revealed "receipt of guidance on adverse events" as the only variable significantly associated with the presence of four or more adverse events to antiretroviral therapy (OR = 4.183 ; CI 95% = 1.775-9.855). Conclusions: Results suggest difference in perception of adverse events between patients who received and those who did not receive guidance in this regard, which indicates the importance of health professionals to provide specific information to their patients regarding adverse events to antiretroviral therapy. Thus the patient can understand the effects generated by the treatment and inform these Factors associated with the occurrence of adverse events to antiretroviral therapy in adults and elderly living with HIV Rev Ciênc Farm Básica Apl. 2021;42:e734 2/16 professionals for the notification of adverse events, in order to improve pharmacovigilance actions and promote patient safety.