Finally, through univariate Cox and LASSO regression analyses, we constructed an EMT- and immune-related gene signatures based on IL1R2, S100A12, and CCL8 by using their expression in bronchoalveolar lavage cells of IPF patients, and K–M and ROC analyses revealed that the EMT- and immune-related gene signatures could well predict the 1-, 2-, and 3-year survival of IPF patients. This evidence concerns the gene S100A12 and idiopathic pulmonary fibrosis.