Cloudy, smelly urine is most often caused by dehydration or a urinary tract infection (UTI). Normal urine is transparent and light yellow. If yours looks milky or hazy (the kind you couldn’t see through if you poured it into a glass), something is changing its composition. The smell and cloudiness can share the same cause or come from two separate things happening at once.
Dehydration: The Most Common Cause
Your urine always contains ammonia, a byproduct of the waste compound urea that your kidneys filter out of your blood. When you’re well-hydrated, water dilutes the ammonia so the smell is faint and the urine stays pale. When you haven’t had enough fluids, the concentration of ammonia and other waste products rises sharply, producing a strong, pungent odor and a darker, cloudier appearance.
This is by far the most frequent explanation, especially if the change showed up on a hot day, after exercise, or on a morning when you didn’t drink much the night before. Drinking more water over a few hours typically brings both the color and smell back to normal. If it does, there’s generally nothing else going on.
Urinary Tract Infections
UTIs are the second most common reason for cloudy, foul-smelling urine, and they’re worth considering if dehydration doesn’t explain it. When bacteria colonize the urinary tract, your immune system floods the area with white blood cells. Those cells, along with the bacteria themselves, cloud the urine and give it a distinctly unpleasant odor that’s different from the sharp ammonia smell of concentrated urine. A urine sample with more than 10 white blood cells per microscope field is considered abnormal and strongly suggestive of infection in someone with symptoms.
Other signs of a UTI include a burning sensation when you pee, feeling like you need to go constantly even when your bladder is nearly empty, and pelvic pressure or discomfort. UTIs are far more common in women due to a shorter urethra, but men get them too. A simple urine dipstick test at a clinic can detect the chemical markers of infection and guide treatment quickly.
Foods and Supplements That Change Urine Smell
Certain foods alter urine odor noticeably. Asparagus is the most well-known culprit. It contains a sulfur compound that breaks down during digestion and produces a distinctive smell within 15 to 30 minutes of eating it. Coffee, garlic, onions, and certain spices can do the same. B vitamins, especially in high-dose supplements, can make urine both brighter in color and stronger-smelling. These changes are harmless and temporary, usually clearing within a day.
Crystals and Kidney Stones
Minerals in your urine can clump together into microscopic crystals made of calcium, uric acid, or other compounds. When enough crystals form, they make urine visibly cloudy and can produce a bad smell. You might also notice pain in your lower back or side, a frequent urge to urinate, or blood in your urine. These crystals can eventually grow into kidney stones if the underlying conditions persist, so recurring cloudiness with pain is worth investigating. Staying well-hydrated is one of the most effective ways to prevent crystal buildup.
Kidney Disease and Excess Protein
Healthy kidneys keep proteins in your blood and out of your urine. When the kidneys are damaged, protein leaks through, and urine can turn cloudy or develop small foamy bubbles that don’t go away when you flush. This is different from the hazy, milky look of infection or dehydration. It tends to be persistent and may appear alongside swelling in your ankles or feet, fatigue, or changes in how much you urinate. Cloudy urine with persistent foam is one of the earlier visible signs of kidney problems.
Prostate and Vaginal Infections
In men, an inflamed prostate (prostatitis) can introduce white blood cells and discharge into the urine stream because the prostate gland wraps directly around the urethra. This produces cloudy urine along with pelvic pain, difficulty urinating, or discomfort during ejaculation.
In women, vaginal infections like bacterial vaginosis or yeast infections can cause discharge that mixes with urine during collection, making it look cloudy and smell off. The key difference is that the odor and discharge are usually present outside of urination too. If the smell or cloudiness only appears in your urine and not on its own, a urinary cause is more likely.
Diabetes and Ketones
When your body can’t use glucose for energy, either because of insufficient insulin or uncontrolled diabetes, it starts breaking down fat instead. This process produces ketones, chemicals that spill into the urine and give it a distinctive sweet or fruity smell. This is different from the sharp ammonia odor of dehydration or the foul smell of infection. If your urine smells sweet or fruity and you’re also experiencing excessive thirst, frequent urination, or unexplained weight loss, blood sugar levels may be the issue. People already diagnosed with diabetes should check for ketones when blood glucose rises above 200 mg/dL.
How to Tell What’s Causing It
Start with the simplest explanation. Drink several glasses of water over a few hours and see if the next time you urinate, things look and smell normal again. If they do, dehydration was the answer.
If cloudiness and odor persist for more than two or three days despite good hydration, or if you notice any of the following, something else is likely going on:
- Burning or pain while urinating, which points toward infection
- Back or side pain, which may suggest kidney stones or a kidney infection
- Fever or chills, which signal the infection may have moved beyond the bladder
- Blood in urine, which can accompany stones, infections, or kidney disease
- Persistent foam or bubbles, which may indicate protein in the urine
A basic urinalysis can identify bacteria, white blood cells, protein, crystals, and ketones in one test. It’s quick, inexpensive, and gives a clear picture of what’s happening. Most causes of cloudy, smelly urine are treatable once identified.

