BACKGROUND: Infection of the surgical site is one of the most frequent complications in the postoperative patients. Despite the continuous improvement of surgical techniques and antibiotic prophylaxis, this complication represents 38% of all nosocomial infections; it increases hospital stay, increases morbidity, mortality, and raises costs per patient. The aim of this study is to determine the prevalence of surgical site infection in herniorrhaphy and hernioplasty, and its associated factors, in patients treated at “Hospital de Especialidades José Carrasco Arteaga”, in Cuenca, from 2016 to 2018. METHODS: Analytical, cross-sectional study, based on 203 patients who underwent surgical hernia repair, in the period from January 2016 to December 2018. Analysis was performed with Pearson's Chi-square non-parametric statistic. To determine the association of risk factors, the Odds Ratio measure was used, with a 95% CI and values> 1; statistical significance was established with the p value <0.05. RESULTS: The prevalence of surgical site infection was 8.9%, and it was found to be associated with the type of hernia (OR: 3.57 p= 0.046) and use of drains (OR: 3.2 p+ 0.026). No association could be determined with the factors: smoking, diabetes, hypertension, immunosuppression, ASA index, use of prosthetic material, surgical approach or surgical emergency. CONCLUSION: The prevalence of surgical site infection is 8.9% and is statistically associated with factors related to surgical management such as the type of hernia(p=0.046) and the use of drains (p= 0.026).