Tuberculosis (TB) is preventable. Good ventilation can stop the spread of TB, which passes from person to person through the air. Hospitals quarantine contagious TB patients in rooms with separate ventilation systems, and they use ultraviolet light to sanitize the air. Healthcare workers may wear respirator masks to protect themselves.
Even if you have been infected with TB bacteria, you can prevent the disease itself by taking certain antibiotics for several months. There is a tuberculosis vaccine, known as bacille Calmette-Guerin (BCG), but it is given mostly to children in developing nations where the risk of TB is high. The vaccine doesn't work well in adults, and it can cause false-positive tuberculosis tests later in life, so it isn't widely used in the United States.