Current treatments for tuberculosis (TB) are effective in controlling Mycobacterium tuberculosis (Mtb) growth, yet have significant side effects and do not prevent reinfection. Therefore, it is critical to understand why our host defense system is unable to generate permanent immunity to Mtb despite prolonged anti-tuberculosis therapy (ATT). Here, we demonstrate that treatment of mice with the most widely used anti-TB drugs, rifampicin (RIF) or isoniazid (INH) and pyrazinamide (PYZ), significantly altered the composition of the gut microbiota. Unexpectedly, treatment of mice with the pro-Mtb drugs INH and PYZ, but not RIF, prior to Mtb infection resulted in an increased bacterial burden, an effect that was reversible by fecal transplantation from untreated animals. Mechanistically, susceptibility of INH/PYZ-treated mice was associated with impaired metabolism of alveolar macrophages and defective bactericidal activity. Collectively, these data indicate that dysbiosis induced by ATT administered to millions of individuals worldwide may have adverse effects on the anti-Mtb response of alveolar macrophages.