Family Health|Infants and Toddlers

Pneumonia and Walking Pneumonia

Last Updated June 2024 | This article was created by editorial staff and reviewed by Deepak S. Patel, MD, FAAFP, FACSM

What is pneumonia?

Pneumonia is an infection of the lungs. It causes the air sacs (alveoli) of the lungs to get inflamed (irritated and swollen). They may fill up with fluid or pus. This causes a variety of symptoms, which range from mild to severe. Pneumonia is usually caused by bacteria or a virus. It also can be caused by fungi or irritants that you breathe into your lungs. How serious pneumonia is depends on many factors. These include what caused the pneumonia, your age, and your overall health.

Symptoms of pneumonia

The symptoms of pneumonia can range from mild to severe. This depends on your risk factors and the type of pneumonia you have. Common symptoms are similar to the symptoms caused by a cold or the flu. They include:

  • cough
  • fever
  • bringing up mucus when you cough
  • difficulty breathing
  • chills
  • chest pain

You may also sweat, have a headache, and feel very tired. Some people also experience nausea, vomiting, and diarrhea.

If any of these symptoms are severe, call your family doctor. You should also call your doctor if you suddenly start getting worse after having a cold or the flu.

What is walking pneumonia?

Walking pneumonia is a mild case of pneumonia. It is often caused by a virus or the mycoplasma pneumoniae bacteria. When you have walking pneumonia, your symptoms may not be as severe or last as long as someone who has a more serious case of pneumonia. You probably won’t need bed rest or to stay in the hospital when you have walking pneumonia.

What causes pneumonia?

Most cases of pneumonia are caused by:

  • Bacteria are the most common cause of pneumonia in adults. They can cause pneumonia on their own, or after you’ve had a cold or the flu. Bacterial pneumonia usually only affects one area of a lung.
  • Any virus that affects the respiratory tract can cause pneumonia. This includes the flu virus and the virus that causes the common cold. In children under 1 year old, the respiratory syncytial virus (RSV) is the most common cause. Viral pneumonia tends to be mild. It often gets better on its own in 1 to 3 weeks.
  • Some fungal infections can lead to pneumonia, especially in people with weakened immune systems. There are also some fungi that occur in the soil in certain parts of the United States that can lead to pneumonia.

You can also get pneumonia through aspiration. This is when you inhale particles into your lungs. These could be food, saliva, liquids, or vomit. It occurs most often after vomiting, and you are not strong enough to cough the particles out. The particles cause irritation, swelling and can get infected. This causes pneumonia.

How is pneumonia diagnosed?

Pneumonia can sometimes be hard to diagnose because the symptoms are the same as for a bad cold or flu. If you think it could be pneumonia, you should see your doctor. Your doctor may diagnose pneumonia based on your medical history and the results from a physical exam. He or she will listen to your lungs with a stethoscope. Your doctor may also do some tests, such as a chest X-ray or a blood test. A chest X-ray can show your doctor if you have pneumonia and how widespread the infection is. Blood and mucus tests can help your doctor tell whether bacteria, a virus, or a fungal organism is causing your pneumonia.

Can pneumonia be prevented or avoided?

There are many factors that can raise your risk for developing pneumonia. These include:

  • Your age. People older than 65 are at increased risk because the immune system becomes less able to fight off infection as you age. Infants age 2 or younger are also at increased risk because their immune systems haven’t fully developed yet.
  • Your environment. Regularly breathing in dust, chemicals, air pollution, or toxic fumes can damage your lungs. This makes your lungs more vulnerable to infection.
  • Your lifestyle. Habits such as smoking cigarettes or abusing alcohol can increase your risk. Smoking damages the lungs, while alcohol interferes with how your body fights infection.
  • Your immune system. If your immune system is weakened, it’s easier for you to get pneumonia because your body can’t fight off the infection. This could include people who have HIV/AIDS, have had an organ transplant, are receiving chemotherapy, or have long-term steroid use.
  • If you are hospitalized, especially in an ICU. Being in the ICU (intensive care unit) raises your risk of pneumonia. Your risk increases if you are using a ventilator to help you breathe. Ventilators make it hard for you to cough and can trap germs that cause infection in your lungs.
  • If you have recently had major surgery or a serious injury. Recovering from major surgery or injury can make it difficult for you to cough. This is the body’s quickest defense for getting particles out of the lungs. Recovery also typically requires a lot of bed rest. Lying down on your back for an extended period of time can allow fluid or mucus to gather in your lungs. This gives bacteria a place to grow.

People who have any of the following conditions are also at increased risk:

  • chronic obstructive pulmonary disease (COPD)
  • asthma
  • heart disease
  • emphysema
  • diabetes
  • sickle cell disease

You can help prevent pneumonia by doing the following:

  • Get the flu vaccine each year. People can develop bacterial pneumonia after a case of the flu. You can reduce this risk by getting the yearly flu shot.
  • Get the pneumococcal vaccine. This helps prevent pneumonia caused by pneumococcal bacteria.
  • Practice good hygiene. Wash your hands frequently with soap and water or an alcohol-based hand sanitizer.
  • Don’t smoke. Smoking damages your lungs and makes it harder for your body to defend itself from germs and disease. If you smoke, talk to your family doctor about quitting as soon as possible.
  • Practice a healthy lifestyle. Eat a balanced diet full of fruits and vegetables. Exercise regularly. Get plenty of sleep. These things help your immune system stay strong.
  • Avoid sick people. Being around people who are sick increases your risk of catching what they have.

Is there a vaccine for pneumonia?

There isn’t a vaccine for all types of pneumonia, but 2 vaccines are available. These help prevent pneumonia caused by pneumococcal bacteria. The first is recommended for all children younger than 5 years of age. The second is recommended for anyone age 2 or older who is at increased risk for pneumonia. Getting the pneumonia vaccine is especially important if you:

  • Are 65 years of age or older.
  • Have certain chronic conditions, such as asthma, lung disease, diabetes, heart disease, sickle cell disease, or cirrhosis.
  • Smoke.
  • Have a weakened immune system because of HIV/AIDS, kidney failure, a damaged or removed spleen, a recent organ transplant, or receiving chemotherapy.
  • Have cochlear implants (an electronic device that helps you hear).

The pneumococcal vaccines can’t prevent all cases of pneumonia. But they can make it less likely that people who are at risk will experience the severe, and possibly life-threatening, complications of pneumonia.

Pneumonia treatment

Treatment for pneumonia depends on several factors. These include what caused your pneumonia, how severe your symptoms are, how healthy you are overall, and your age.

For bacterial pneumonia, your doctor will probably prescribe antibiotics. Most of your symptoms should improve within a few days. A cough can last for several weeks. Be sure to follow your doctor’s directions carefully. Take all the antibiotic medicine that your doctor prescribes. If you don’t, some bacteria may stay in your body. This can cause your pneumonia to come back. It can also increase your risk of antibiotic resistance.

Antibiotics don’t work to treat viral infections. If you have viral pneumonia, your doctor will likely talk to you about ways to treat your symptoms. Over-the-counter (OTC) medicines are available to lower fever, relieve pain, and ease your cough. However, some coughing is okay because it can help clear your lungs. Be sure to talk to your doctor before you take a cough suppressant.

If a fungus is causing your pneumonia, your doctor may prescribe an antifungal medicine.

If your case of pneumonia is severe, you may need to be hospitalized. If you are experiencing shortness of breath, you may be given oxygen to help your breathing. You might also receive antibiotics intravenously (through an IV). People who have weakened immune systems, heart disease or lung conditions, and people who were already very sick before developing pneumonia are most likely to be hospitalized. Babies, young children, and adults who are 65 years of age and older are also at increased risk.

What can I do at home to feel better?

In addition to taking any antibiotics and/or medicine your doctor prescribes, you should also:

  • Get lots of rest. Rest will help your body fight the infection.
  • Drink plenty of fluids. Fluids will keep you hydrated. They can help loosen the mucus in your lungs. Try water, warm tea, and clear soups.
  • Stop smoking if you smoke and avoid secondhand smoke. Smoke can make your symptoms worse. Smoking also increases your risk of developing pneumonia and other lung problems in the future. You should also avoid lit fireplaces or other areas where the air may not be clean.
  • Stay home from school or work until your symptoms go away. This usually means waiting until your fever breaks and you aren’t coughing up mucus. Ask your doctor when it’s okay for you to return to school or work.
  • Use a cool-mist humidifier or take a warm bath. This will help clear your lungs and make it easier for you to breathe.

Living with pneumonia

Your doctor may schedule a follow-up appointment after he or she diagnoses you with pneumonia. At this visit, he or she might take another chest X-ray to make sure the pneumonia infection is clearing up. Keep in mind that chest X-rays can take months to return to normal. However, if your symptoms are not improving, your doctor may decide to try another form of treatment.

Although you may be feeling better, it’s important to keep your follow-up appointment. The infection can still be in your lungs even if you’re no longer experiencing symptoms.

When should I see my doctor?

Pneumonia can be life-threatening if left untreated, especially for certain at-risk people. You should call your doctor if you have a cough that won’t go away, shortness of breath, chest pain, or a fever. You should also call your doctor if you suddenly begin to feel worse after having a cold or the flu.

Questions to Ask Your Doctor

  • I have a chronic condition. Am I at higher risk for pneumonia?
  • Do I have bacterial, viral, or fungal pneumonia? What’s the best treatment?
  • Am I contagious?
  • What are the possible complications of pneumonia? How will I know if I’m developing complications?
  • How serious is my pneumonia? Will I need to be hospitalized?
  • What can I do at home to help relieve my symptoms?
  • What should I do if my symptoms don’t respond to treatment or get worse?
  • Do we need to schedule a follow-up exam?
  • Do I need any vaccines?
@media print { @page { padding-left: 15px !important; padding-right: 15px !important; } #pf-body #pf-header-img { max-width: 250px!important; margin: 0px auto!important; text-align: center!important; align-items: center!important; align-self: center!important; display: flex!important; }