Medically Reviewed by Minesh Khatri, MD on August 22, 2021

What Is It?


Pneumonia starts when a virus, fungus, or bacterium get into one of your lungs. It causes the tiny sacs inside to get inflamed and fill with fluid or pus. If you’re healthy and get treated right away, it usually isn’t serious. But it can be dangerous for young kids, the elderly, and people who have other health problems or weak immune systems.

How It Happens


Most of the time, your body filters germs from the air to protect your lungs. Coughing also helps keep them out. If they do get in, your immune system usually fights them off before they make you sick. But if the germ is really strong or your body can’t do its part, your lungs can get infected. When your immune system sends cells to attack the germs, your lungs get inflamed, and that leads to pneumonia.



You may have a high fever, chills, shortness of breath, and chest pain when you breathe. You’ll also probably have a deep cough that doesn’t go away and brings up a thick liquid called phlegm. If you’re able to go about your daily business with these symptoms, you might have “walking pneumonia,” which is often caused by a certain kind of bacteria called Mycoplasma pneumoniae. But if your symptoms are worse than that, you should see your doctor.

Cause: Bacteria


Some of these tiny organisms are a natural and healthy part of your body, like in your gut, where they help you digest food. Others can make you sick. Most cases of pneumonia in U.S. adults are caused by bacteria. Antibiotics can kill them and help you get better.

Legionnaires’ Disease


This less common form of pneumonia is caused by Legionella bacteria. You may have a headache, muscle pain, chills, and very high fever. You may also cough up blood and have nausea, vomiting and diarrhea. It spreads through water and can get in things like air conditioners, hot tubs, and mist sprayers in grocery stores. It’s also treated with antibiotics.

Cause: Virus


The flu virus is the most common cause of viral pneumonia in adults, but any virus that infects your mouth, nose, throat, or lungs can lead to it. The symptoms are usually milder than with bacterial pneumonia, and your body typically fights it off in 1 to 3 weeks.

Cause: Fungi


Some of these are useful: Mushrooms are a kind of fungus, and mold is what makes blue cheese blue. But some can cause pneumonia. Antifungal drugs are usually used to treat it, but people who have HIV or AIDS or who take drugs that make their immune systems weak, like some cancer drugs, can get a kind called pneumocystis pneumonia. It’s more serious and can be hard to get rid of.



You may not know you have pneumonia. It can seem a lot like a cold or the flu -- until it doesn’t go away. Your doctor will ask about your symptoms and when they started, and they’ll listen to your lungs for crackling or wheezing. They may want a chest X-ray to get an image your lungs. It can tell for sure if you have pneumonia, but it won’t show what’s causing it.   

Bacteria, Virus, or Fungus?


It’s not always easy to find out what’s caused your pneumonia. Phlegm from your cough can be tested for bacteria, and urine tests can sometimes tell your doctor what’s causing it. They also may ask about recent travel, hobbies, animals, sick people you’ve been around, vaccinations, and drugs you take. 

Complication: Lung Abscess


This is a sore in your lung that’s filled with fluid or pus. In most cases, antibiotics are enough to get rid of it, but your doctor may recommend draining it with a long needle or possibly surgery. A CT scan can help your doctor see it better. This is when several X-rays are put together to make a more detailed picture of your chest.

Complication: Bacteremia


This is when bacteria from your lungs get into your blood -- it’s more likely to happen if you have certain other health issues, like liver disease or high blood pressure. It may spread to other organs, which can cause them to shut down. A blood test can tell if you have it, and it’s usually treated with powerful antibiotics put directly into a vein in your hand or arm.

Complication: Trouble Breathing


If you’re older, have other health problems, or your pneumonia is serious, your lungs may not work the way should. If they don’t, you may not have enough oxygen in your blood, which your brain, muscles, and other organs need. Your doctor can find out if this is the case with a blood test or a sensor on your finger. You may need to get more oxygen through a breathing mask, or possibly use a machine to help you breathe -- called a ventilator -- until your lung heals.

Complication: Pleural Effusion


Sometimes called water on the lungs, pneumonia can make fluid build up in the tissue around your lungs. If the fluid gets infected or makes it really hard for you to breathe, your doctor may need to put a tube in your chest or do surgery to drain it. 



Vaccines can protect you from certain kinds, but good habits also help. Keep your hands and face clean with soap or hand sanitizer to kill the germs that cause it. Eat a healthy diet and exercise regularly to keep your immune system strong. And don't smoke -- that makes it harder for your lungs to fight off germs and can lead to more health problems if you do get pneumonia.

Show Sources


1) Kevin Somerville / Medical Images

2) selvanegra / Thinkstock

3) Science Photo Library / Getty Images

4) iLexx / Thinkstock

5) Bepsimage / Thinkstock

6) Eraxion / Getty Images

7) Michael Abbey / Science Source

8) Ariel Skelley / Getty Images

9) Arno Massee / Science Source

10) Dr. M. Brauner / Science Source

11) Dr_Microbe / Thinkstock

12) SPL / Science Source

13) Zephyr / Science Source

14) Purestock / Thinkstock



CDC: “Pneumocystis pneumonia.”

Cleveland Clinic: “Pleural Effusion: Heart & Vascular Institute Overview.”

Mayo Clinic: “Pneumonia,” “Legionnaires' disease,” “Walking pneumonia: What does it mean?”

National Institutes of Health: “Explore Pneumonia: Risk Factors,” “Explore Pneumonia: Signs, Symptoms, and Complications,” “Explore Pneumonia: Diagnosis,” “Explore Pneumonia: Treatment,” “Explore Pneumonia: Prevention,” “Explore Pneumonia: Causes,” “Explore Pneumonia: Pneumonia.”