Objective By utilizing a structural equation model, to analyze determinants that affect the hospitalization costs for individuals with inguinal hernia at a tertiary-level comprehensive medical center, offering insights for the potential management of costs associated with this specific ailment. Methods This study entailed the compilation of 4 328 patient files from individuals who received surgical treatment for inguinal hernia at a third-level general hospital over the period spanning 2016 to 2022. Preliminary analysis was conducted on isolated variables, followed by the development of a model using AMOS 28. 0 for fit assessment. Results The fitting of structural equation model reached the standard. The total effect values of gender, age, cost, number of hospitalizations, admission route, concomitant disease, unilateral and bilateral hernia on the total cost were 0. 008, -0. 044, 0. 062, 0. 014, -0. 119, 0. 106, 0. 236, respectively. Gender, age, cost, number of hospitalizations, admission route, concomitant disease, unilateral and bilateral hernia indirectly affected hospitalization expenses through hospitalization days. Conclusions Gender, age, cost, number of hospitalizations, of admission, concomitant diseases, unilateral and bilateral hernia, and length of hospital stay have an impact on hospitalization costs. It is suggested to implement the pre-hospitalization mode and day surgery, complete relevant examinations before formal hospitalization, and optimize the medical service process, so as to reasonably and effectively control the hospitalization cost of single disease.