Why Does My Pee Smell Like Boiled Eggs? Key Causes

Urine that smells like boiled eggs is caused by sulfur compounds passing through your urinary tract. These compounds, particularly dimethyl disulfide and methanethiol, are the same chemicals responsible for the smell of cooked eggs. In most cases, the culprit is something you ate or drank, but infections, medications, and certain medical conditions can also be responsible.

Why Sulfur Ends Up in Your Urine

Your body constantly processes sulfur-containing amino acids from the protein you eat. As your metabolism breaks these down, it produces volatile sulfur compounds like dimethyl disulfide, hydrogen sulfide, and methanethiol. These byproducts circulate in your blood, get filtered by your kidneys, and exit in your urine. Normally their concentration is low enough that you don’t notice. But when something tips the balance, whether it’s a large serving of garlic or a bacterial infection, those sulfur compounds spike and the smell becomes unmistakable.

Foods That Trigger the Smell

Asparagus is the most well-known dietary trigger. It contains asparagusic acid, a sulfur-rich compound that your body breaks down and sends straight to your kidneys. The resulting smell can appear within 15 to 30 minutes of eating it. Not everyone notices it: some people lack the gene needed to detect the odor, so they may produce it without ever knowing.

Garlic and onions are close behind. Both are loaded with sulfur compounds that give them their sharp, pungent flavor. After digestion, some of those same compounds are released into your urine. Cruciferous vegetables like broccoli, Brussels sprouts, and cabbage work the same way. A meal heavy in any combination of these foods can produce a noticeably eggy smell for several hours afterward.

If food is the cause, the smell is temporary. It resolves once your body finishes processing the meal, usually within 24 hours.

Dehydration Concentrates the Odor

When you’re not drinking enough water, your kidneys produce less urine, but the same amount of waste products still need to leave your body. The result is more concentrated urine that’s darker in color and stronger in smell. Sulfur compounds that would normally be diluted enough to go unnoticed become far more apparent. If your urine is dark yellow or amber alongside the boiled egg smell, dehydration is likely amplifying the problem. Drinking enough fluid to keep your urine light yellow typically resolves this on its own.

Urinary Tract Infections

Bacteria that cause UTIs don’t just multiply in your urinary tract. They actively produce sulfur gases as they feed on amino acids in your urine. A bacterium called Proteus mirabilis is particularly known for converting the amino acid methionine into methanethiol and dimethyl disulfide, both of which have a strong rotten egg or boiled egg odor. Other common UTI bacteria, including E. coli, Klebsiella, and Staphylococcus aureus, also produce sulfur compounds, though in different amounts.

A sulfur smell alone doesn’t confirm a UTI, but if it comes with burning during urination, cloudy or discolored urine, fever, chills, or lower back pain, an infection is the most likely explanation. UTIs are diagnosed with a simple urine test and treated with antibiotics.

Medications and Supplements

Two common medication categories can make your urine smell sulfurous. The first is B vitamin supplements, especially those containing B6. These alter your body’s chemical balance in ways that increase sulfur byproducts in urine. The second is sulfa drugs, a class of medications used to treat conditions ranging from infections to rheumatoid arthritis to diabetes. The sulfur in these drugs is processed by your kidneys and can produce a noticeable eggy odor.

If a supplement or medication is the cause, the smell is consistent rather than occasional. Switching to a different form of the supplement (a B12 injection instead of an oral tablet, for example) or discussing alternative medications with your provider can help.

Pregnancy and Hormonal Changes

Pregnant women frequently report changes in urine odor, and there are a few overlapping reasons. Prenatal vitamins, particularly those high in B6, can shift the smell toward sulfur. Dehydration is more common during pregnancy, especially in the first trimester when nausea makes it harder to keep fluids down. And pregnancy itself heightens the sense of smell, a phenomenon called hyperosmia, which means you may be detecting odors that were always there but previously too faint to notice.

A persistent sulfur smell during pregnancy alongside other urinary symptoms is worth flagging to your provider, since UTIs are more common during pregnancy and can carry additional risks.

Less Common Medical Causes

A rare genetic condition called cystinuria causes your kidneys to leak an amino acid called cystine into your urine. Because cystine contains sulfur, people with this condition often describe their urine as smelling like rotten eggs. Cystinuria also causes kidney stones, so recurrent stones alongside sulfur-smelling urine is a recognizable pattern.

Liver disease is another, more serious possibility. When your liver loses its ability to filter certain toxins from your blood, volatile sulfur compounds like dimethyl sulfide and methanethiol build up and get released through your breath, sweat, and urine. The resulting odor has been compared to rotten eggs mixed with garlic. This smell, called fetor hepaticus, signals advanced liver dysfunction. It would almost always come alongside other symptoms like jaundice, abdominal swelling, fatigue, or confusion.

How to Tell What’s Causing It

Start with the simplest explanations. Think about what you’ve eaten in the last 12 to 24 hours and how much water you’ve been drinking. If asparagus, garlic, onions, or cruciferous vegetables were on the menu, that’s your likely answer. If you recently started a new supplement or medication, check the label for B vitamins or sulfur-based ingredients.

If the smell persists for more than a couple of days without an obvious dietary explanation, or if it’s accompanied by pain, burning, fever, or changes in urine color or clarity, those are signs that something beyond diet is going on. A urinalysis can quickly rule in or out infection, and further testing can identify rarer causes if needed.