Autophagy is closely involved in the control of mycobacterial infection. Here, a diagnostic model was developed using the levels of autophagy-related genes (ARGs) in the blood to differentiate active tuberculosis (ATB) and latent tuberculosis infection (LTBI). Secondary data analysis of three prospective cohorts. The expression of ARGs in patients with ATB and LTBI were analyzed using the GSE37250, GSE19491, and GSE28623 datasets from the GEO database. Twenty-two differentially expressed ARGs were identified in the training dataset GSE37250. Using least absolute shrinkage and selection operator and multivariate logistic regression, three ARGs (FOXO1, CCL2, and ITGA3) were found that were positively associated with adaptive immune-related lymphocytes and negatively associated with myeloid and inflammatory cells. A nomogram was constructed using the three ARGs. The accuracy, consistency, and clinical relevance of the nomogram were evaluated using receiver operating characteristic curves, the C-index, calibration curves, and validation in the datasets GSE19491 and GSE28623. The nomogram showed good predictive performance. The nomogram was able to accurately differentiate between ATB and LTBI patients. These findings provide evidence for future study on the pathology of autophagy in tuberculosis infection.