In the last 40 years, a significant increase in the incidence of lung infections by Aspergillus has been reported. The scarcity of studies that describe the costs of aspergillosis indicates that the economic impact of aspergillosis in the hospital environment is greater than that of other fungal infections. The objective of the study was to evaluate the direct healthcare costs associated with aspergillosis in the Spanish National Health System from 1997 to 2021. A retrospective nationwide longitudinal descriptive study was designed to review hospital records from the Minimum Basic Data Set of patients admitted to hospitals of the National Health System from 1997 to 2021, with a diagnosis of aspergillosis. A total of 44,586 patients were admitted for aspergillosis in the Spanish National Health System. There was a progressive increase in the average annual cost from 1997 to 2012, which reached a maximum peak, EUR 1,395,154.21 (±2,155,192.87). It decreased between 2014 and 2019, but increased again in 2020 and 2021, EUR 28,675.79 (±30,384.12). The Pearson correlation coefficient revealed a weak negative correlation between age and hospital costs and a moderate positive correlation between average length of stay and hospital costs. Our data show that the economic impact of hospitalizations for aspergillosis is significant and increasing at a rate proportionally higher than that of other prevalent diseases. Costs related to Aspergillus infection are associated mainly with respiratory diseases. The results of this economic evaluation may be useful for health authorities to develop a future economic strategy for managing this fungal infection.