Skip to main content
Read about

Coughing Up Green or Yellow Phlegm

Mucus is your body’s way of dealing with an infection, and it’s not always bad.
Man coughing and showing viruses in the background
Tooltip Icon.
Medically reviewed by
Last updated November 13, 2024

Phlegm quiz

Take a quiz to find out what's causing your phlegm.

What is phlegm?

When you get a cough, you may start to see thicker, darker mucus come up. Mucus is a normal fluid produced by many parts of the body.

It keeps certain tissue in your body from drying out. It’s also your body’s front line of defense because it traps germs and other foreign particles.

Phlegm is a type of mucus that your lungs produce and comes up when you cough. When you cough up a lot of phlegm and it’s yellow or green, it usually means you have an infection or other lung condition.

How mucus does its job

The airways of the lung constantly make mucus. The cells that line the airways have small hairs called cilia.

The cilia rhythmically beat back and forth, sweeping mucus up out of the airways and into the mouth. The mucus takes with it any foreign particles, like dirt, dust, or bacteria. This keeps the airways clean and free from infection.

What can you tell by the color and consistency of phlegm?

When the lungs become infected, either from bronchitis (inflammation of bronchial tubes) or pneumonia (inflammation of air sacs), they often create more mucus.

Infection may cause mucus to change from a clear or light yellow thinner liquid to a darker thicker one. Mucus can become darker yellow or green. The dead white blood cells and other changes from the body’s response to infection cause this color change. The change in color may mean that your body is fighting off an infection. But not always.

There is some evidence that green or yellow phlegm is more often caused by a bacterial infection (as opposed to a virus). It’s just not a guarantee, so your doctor will look at other symptoms to decide which type of infection you have—a bacterial one or a viral one.

Are antibiotics needed to treat green or yellow phlegm?

"It is a common misconception that a cough with new green or yellow phlegm means you have a bacterial infection needing antibiotics. The phlegm may be from a variety of infections (viruses or bacteria) and rarely are antibiotics required in those without an underlying lung condition. For common chest colds, antibiotics do not decrease the duration of symptoms and can have dangerous side effects." —Dr. Benjamin Ranard

Other symptoms you may have

If you have mild symptoms such as a cough, congestion, and sore throat for a few days, it’s likely you have a common cold from a virus. Colds can make you cough up phlegm as the body fights the infection. But once the infection is gone, the phlegm should also go away.

Longer lasting symptoms, or more severe symptoms such as fever or shortness of breath may indicate a bacterial infection (such as pneumonia) that requires an antibiotic. You will only be given antibiotics for bacterial infections, since antibiotics don’t help fight off viruses.

Sometimes, you can have brown or red phlegm. This is usually caused by some bleeding, which can happen from an infection, but can also be from other conditions.

A small amount of red-tinged phlegm that goes away within a few days and occurs while you’re sick with an infection is generally nothing to worry about. However, you should let your doctor know this happened next time you see them.

Call your doctor if you’re coughing up any significant blood or go to the emergency room if your doctor is not available.

Is it normal to have constant phlegm?

"If you’ve been living with chronic cough and mucus, talk to your doctor about what may be causing the mucus. There may be easy treatments for the underlying cause—and it is important to try and figure out if there is an underlying condition causing the mucus." —Dr. Ranard

Other causes of phlegm

Exposure to toxins or chemicals (like cigarette smoke) can make you produce more mucus. The lining of the airways become irritated and produce mucus to help clear away the pollutants. Over time smoking can lead to increased mucus production even after quitting smoking.

People with a lung condition, such as chronic obstructive pulmonary disease (COPD), may also have darker yellow or green phlegm. This disease is more common with age. And it is especially common in people who smoke cigarettes.

However, there are other chronic diseases that can lead to more mucus production and more coughing up of phlegm such as cystic fibrosis or bronchiectasis.

Not all mucus comes from the lungs. The nasal passages can create mucus. This can happen from a common cold. It can also be from allergies such as hay fever.

When the mucus drips down the back of the throat (postnasal drip), it can cause coughing that is sometimes mistaken as phlegm coming from the lungs.

What questions will your doctor ask?

"I want to know how long has this been going on? Is it getting better or worse? And whether anything seems to improve or worsen the condition." —Dr. Ranard

Phlegm quiz

Take a quiz to find out what's causing your phlegm.

Take symptoms quiz

How to get rid of phlegm

Phlegm that occurs with mild symptoms can be treated at home. You can try taking an over-the-counter cough suppressant (such as dextromethorphan) and/or an exportant to help thin the mucous (such as guaifenesin). Be sure to follow the directions on the package.

If you have more severe or long-lasting symptoms, you should see a doctor. They can help figure out what is causing the phlegm and the best way to treat it.

Phlegm treatment quiz

Take a quiz to find out how to treat your symptoms.

Take treatment quiz

Share your story
Once your story receives approval from our editors, it will exist on Buoy as a helpful resource for others who may experience something similar.
The stories shared below are not written by Buoy employees. Buoy does not endorse any of the information in these stories. Whenever you have questions or concerns about a medical condition, you should always contact your doctor or a healthcare provider.
Dr. Le obtained his MD from Harvard Medical School and his BA from Harvard College. Before Buoy, his research focused on glioblastoma, a deadly form of brain cancer. Outside of work, Dr. Le enjoys cooking and struggling to run up-and-down the floor in an adult basketball league.

Was this article helpful?

101 people found this helpful
Tooltip Icon.
Read this next
Slide 1 of 4