Blue or Green Urine: Medications, Dyes, and Rare Causes

Quick Answer

Blue or green urine looks alarming but is usually harmless. The most common causes are medications, medical test dyes, and food dyes. In most cases, the color clears once the drug or dye leaves your system, often within a day or two.

The color deserves a closer look when it persists without a clear cause, or when it comes with fever, pain, burning, or other urinary symptoms. A small number of rare conditions can produce blue or green urine, and a simple urinalysis can sort them out. Use the blue or green urine guide to compare your shade, and read on for the common causes and when to call a doctor.

Medications That Turn Urine Blue or Green

Several drugs are well known for producing blue or green urine. The color is usually harmless and reverses when the drug is stopped, but you should never stop a prescribed medication without talking to your doctor first.

  • Propofol, an anesthetic used during surgery, can turn urine green or blue-green. The effect is temporary and tied to the procedure.
  • Amitriptyline, a tricyclic antidepressant, has been reported to cause blue-green urine in some people.
  • Cimetidine, an acid-reducing drug, can produce blue-green urine in rare cases.
  • Indomethacin, an anti-inflammatory drug, has been linked to blue urine.
  • Triamterene, a diuretic, can cause blue or greenish urine, especially when combined with certain other drugs.
  • Metronidazole and nitrofurantoin, both antibiotics, can darken urine and occasionally produce a blue-green tint.
  • Methylene blue, used in some medical tests and treatments, reliably turns urine blue or green.

If you started a new medication and noticed blue or green urine within a day or two, the drug is the likely cause. Mention it at your next visit so it can be documented, but do not stop the medication on your own.

Medical Test Dyes

Some medical procedures use dyes that are excreted in urine and turn it blue or green. Methylene blue is the best-known example, used in certain diagnostic tests and treatments. Other contrast agents used in imaging can also tint urine, though the color varies by product.

Dye-related color usually appears within hours of the procedure and fades within a day or two. If you had a test or procedure recently, that history is the most useful clue.

Food Dyes and Dietary Causes

Artificial food dyes are a common and easily overlooked cause of blue or green urine, especially in children. Foods and drinks with heavy blue or green coloring can pass pigment into urine.

  • Blue and green food dyes in candies, sports drinks, frostings, and processed foods.
  • Large amounts of asparagus, which can produce a greenish tint in some people.
  • Some artificially colored supplements and vitamin gummies.

Food dye color usually appears within hours of eating and clears within a day. The food dye urine guide explains how artificial colors move through the body and what to expect. If the color persists for several days despite no change in diet, food dye is unlikely to be the whole explanation.

Rare Medical Causes

A small number of medical conditions can produce blue or green urine. These are uncommon, but they are the reason persistent unexplained color deserves a doctor’s look.

  • Pseudomonas urinary tract infection, a bacterial infection that can produce green urine. It often comes with burning, urgency, fever, or flank pain.
  • Familial benign hypercalcemia, a rare inherited condition that can cause blue urine in children.
  • Blue diaper syndrome, a rare metabolic disorder in infants that produces blue urine.
  • Indicanuria, a rare condition linked to gut absorption problems that can tint urine blue or indigo.

These conditions are uncommon, and the vast majority of blue or green urine is explained by drugs, dyes, or food. The key is whether the color persists and whether it comes with other symptoms. If it does, a urinalysis and a conversation with your doctor can narrow it down. The UTI symptom guide covers the infection pattern in more detail.

How Long Does Blue or Green Urine Last?

For most causes, blue or green urine appears within a few hours of the trigger and fades within 24 to 48 hours. Medication-related color follows the drug’s timeline and typically clears within a day or two after the last dose. Food dye color usually clears within a day.

If blue or green urine persists beyond two to three days after stopping the suspected drug or dye, or if it recurs without an obvious trigger, that is the point to check in with a clinician.

When to See a Doctor

Contact a healthcare provider if any of the following applies:

  • Blue or green urine persists for more than a few days and is not explained by food, medication, or a recent medical test.
  • You have fever, chills, burning, urgency, or flank pain, which may point to a urinary tract infection.
  • The color comes with pain, nausea, or vomiting.
  • You notice blood or clots alongside the color change.
  • You feel dizzy, weak, or lightheaded, or you are passing much less urine than usual.
  • You are pregnant and notice a persistent change in urine color.
  • The color appears in a child without an obvious food dye explanation.

A simple urinalysis can check for infection, blood, and other markers, and help sort out whether the color is harmless or part of a broader picture. If you are unsure whether your shade is concerning, the urine color by cause section groups explanations by food, medication, and medical conditions so you can compare your pattern before your appointment.

The Bottom Line

Blue or green urine is usually harmless. Medications such as propofol, amitriptyline, and methylene blue, medical test dyes, and artificial food dyes are the most common explanations, and the color typically clears within a day or two. Rare conditions, including Pseudomonas urinary tract infection and a few inherited disorders, can also produce blue or green urine. Take it seriously when the color persists without a trigger or comes with fever, pain, burning, or other urinary symptoms. If that describes your situation, get it checked. If it does not, review recent foods, medications, and procedures, and watch for the color to normalize.