Toll-like receptors recognize several components of Mycobacterium tuberculosis, the main causative agent of tuberculosis. The signaling pathways leading to activation of the immune response require the MyD88 and TIRAP genes. The hypothesis that polymorphic variants of these genes influenced resistance to pulmonary tuberculosis was tested by a case-control study (400 cases and 400 controls). Heterozygosity at the polymorphic sites MyD88 rs6853 (alleles: A, G) or TIRAP rs8177374 (S180L) (alleles: C, T) is associated with resistance to pulmonary tuberculosis (P: 7.8 × 10(-8) and 2 × 10(-6), respectively). Double heterozygosity confers higher protection levels (P: 10(-14) to 2 × 10(-16)). The logistic regression model displayed that the double homozygous genotype GG/TT predisposes to the disease (odds ratio (OR): 5.78) and the AG/TT genotype combination neutralizes the protective activity exerted by AG (OR: 3.05). The same model showed that the risk of developing the disease increases with age from 31-40 years to 71-80 years (OR: 1.32-13.59).