Green poop is almost always harmless. It typically means one of two things: you ate something with a lot of green pigment, or food moved through your digestive tract faster than usual. In both cases, the color comes down to bile, a yellow-green fluid your liver produces to help digest fat.
Normally, bile starts out green and gradually turns brown as bacteria in your large intestine break it down during digestion. When that process gets cut short or overwhelmed by green pigments from food, your stool keeps some of that green color. Understanding why helps you figure out whether you can ignore it or whether something else is going on.
How Bile Gives Stool Its Color
Your liver releases bile into the upper part of your small intestine every time you eat. Bile is naturally yellow-green, and as it travels through roughly 25 feet of intestine, bacteria chemically transform it into the familiar brown pigment you expect to see. This journey typically takes 24 to 72 hours.
If food passes through your large intestine too quickly, bile doesn’t have time to break down completely. The result is stool that retains a greenish tint. This is the single most common explanation for green poop, and it’s why diarrhea from any cause, whether it’s a stomach bug or a spicy meal, often comes out green. The faster the transit, the greener it looks.
Foods That Turn Stool Green
Chlorophyll, the pigment that makes plants green, is the most obvious dietary culprit. Eating large amounts of spinach, kale, broccoli, arugula, or other leafy greens floods your gut with more green pigment than bile processing can neutralize. You don’t have to eat an unusual amount. A big salad, a green smoothie, or a serving of pesto can be enough.
Artificial food dyes are equally capable. Green or purple frosting, brightly colored candy, grape-flavored drinks, and certain cereals all contain dyes that survive digestion and tint your stool. Blue dye combined with yellow bile is a particularly common route to vivid green poop. Even green food coloring in seasonal treats like St. Patrick’s Day cupcakes or ice cream can do it.
If you can trace the color back to something you ate in the last day or two, that’s almost certainly the explanation, and the color will return to normal on its own once the food clears your system.
Supplements and Medications
Iron supplements are well known for changing stool color, often producing dark green or even black-green stools. This happens because your body absorbs only a fraction of the iron in a typical supplement, and the unabsorbed iron oxidizes as it travels through your gut. If you recently started an iron supplement and noticed the change, that connection is straightforward.
Antibiotics can also cause green stool, but through a different mechanism. They reduce the population of gut bacteria responsible for converting bile pigments to brown. With fewer bacteria doing that job, bile passes through in a less-processed state, keeping its original greenish hue. This effect can last for the duration of your antibiotic course and sometimes a week or two afterward as your gut bacteria repopulate.
Certain laxatives and other medications that speed up digestion have the same net effect: faster transit means less bile breakdown and greener stool.
Infections and Digestive Conditions
Bacterial infections like Salmonella and E. coli can cause green diarrhea. These infections inflame the lining of the intestines, triggering rapid transit and sometimes increasing bile secretion. You’ll typically know it’s an infection rather than a dietary cause because the green stool comes alongside other symptoms: cramping, nausea, fever, or watery diarrhea that lasts more than a couple of days.
Parasitic infections, particularly Giardia (commonly picked up from contaminated water), can also produce green, foul-smelling stools. Giardia interferes with fat absorption in the small intestine, which disrupts normal bile processing.
Chronic conditions that affect nutrient absorption, such as celiac disease or Crohn’s disease, can occasionally cause green stool. In these cases, the intestinal lining is damaged enough that bile and fat aren’t processed efficiently. Green stool from these conditions is rarely the only symptom. It usually accompanies ongoing bloating, weight loss, or persistent diarrhea over weeks or months.
Green Stool in Babies
Green poop in newborns is completely normal. Meconium, the thick, tar-like substance babies pass in their first few days, is dark green to black. As a baby transitions to breast milk or formula, stool color shifts through various shades of green and yellow before settling into a more consistent pattern.
In breastfed babies, green stool sometimes means the baby isn’t getting enough of the higher-fat milk that comes later in a feeding session. If a baby switches breasts too quickly or has a short feeding, they may take in more of the thinner, lower-fat foremilk, which can produce frothy green stools. Letting the baby finish one breast more fully before switching often resolves this.
Babies on protein hydrolysate formula, the type prescribed for milk or soy allergies, frequently have green stool as a normal side effect of how that formula is digested. Iron-fortified formulas can produce darker green stools for the same reason iron supplements do in adults. Diarrhea in infants also turns stool green due to rapid transit, just as it does in adults. And because breastfed newborns are still building up their gut bacteria, they may lack enough of the microbes that convert bile to its typical brown pigment, resulting in persistent greenish tones for the first several weeks.
How Long Green Stool Lasts
When the cause is dietary, green stool usually resolves within one to three days after you stop eating the food responsible. Your gut processes a meal in roughly 24 to 72 hours from start to finish, so you’re essentially waiting for that batch to clear your system.
Green stool from a short illness like food poisoning or a stomach virus typically returns to normal within a week as your digestion slows back down and bile processing catches up. If antibiotics are the cause, expect the color shift to persist until your course ends and your gut bacteria have had a week or so to recover.
When Green Stool Signals a Problem
Green poop on its own, with no other symptoms, is rarely a concern. The color becomes more significant when it arrives with company. Pay attention if your green stool is accompanied by fever, severe abdominal cramping, blood or mucus in the stool, or diarrhea that persists for more than three days. These combinations can point toward a bacterial infection or inflammatory condition that benefits from treatment.
Persistent green stool lasting more than two weeks without an obvious dietary explanation is also worth investigating, particularly if you’re losing weight unintentionally or noticing that your stools are consistently greasy or unusually foul-smelling. These patterns can suggest a malabsorption issue where your small intestine isn’t properly breaking down fats or nutrients.

