Most urinary tract infections are caused by bacteria that normally live in the gut migrating to the urinary tract, where they don’t belong. About 75% of uncomplicated UTIs are caused by a single species: E. coli. The rest are caused by a handful of other bacteria and, in rare cases, fungi. But the full picture of what causes a UTI goes beyond which germ is responsible. Anatomy, hormones, sexual activity, and underlying health conditions all play a role in determining who gets infected and how often.
The Bacteria Behind Most UTIs
E. coli is a normal, harmless part of your digestive system. The problem starts when it travels from the anal area to the opening of the urethra. From there, it can move up into the bladder, multiply, and trigger an infection. The remaining 25% of uncomplicated UTIs are caused by other bacteria, including Klebsiella pneumoniae, Staphylococcus saprophyticus, Enterococcus, and Proteus mirabilis.
What makes E. coli so effective at causing UTIs is its ability to physically grip the bladder wall. These bacteria produce tiny hair-like structures called pili that stick to sugar-containing receptors on the surface of bladder cells. This attachment is strong enough that the normal flow of urine can’t wash the bacteria away. Even more concerning, research has shown that E. coli can actually invade bladder cells, slipping inside them where they’re shielded from both urine flow and the immune system. Once inside, they sit in small membrane-bound compartments, which may explain why some infections are so stubborn or keep coming back.
Why Women Get UTIs Far More Often
The single biggest reason women develop UTIs at much higher rates than men is anatomy. The female urethra is only 3 to 4 centimeters long, while the male urethra is 18 to 20 centimeters. That short distance means bacteria have a much easier path from the outside world to the bladder. On top of that, the female urethral opening sits close to both the vaginal opening and the anus, two areas that harbor large bacterial populations.
The current understanding is that bacteria migrate from the gut to the vaginal area and then to the urethra. This chain of migration, combined with the short urethra, is why UTIs are overwhelmingly more common in women throughout their lives.
Sexual Activity and UTI Risk
Sex is one of the most common triggers for UTIs in women. The physical activity involved moves bacteria from the skin around the genitals toward the urethral opening. This applies to all types of sexual contact, not just intercourse. Oral sex, for instance, can introduce both mouth and genital bacteria to the urethra.
The connection between sex and UTIs is mechanical, not a sign of poor hygiene or a sexually transmitted infection. Peeing after sex helps flush bacteria out of the urethra before they can travel to the bladder. Staying well hydrated also keeps urine flowing regularly, which reduces the time bacteria have to establish themselves.
Hormonal Changes After Menopause
UTI risk rises significantly after menopause, and the reason traces back to estrogen. Before menopause, estrogen supports a healthy population of Lactobacillus bacteria in the vagina and urinary tract. These beneficial bacteria produce lactic acid, keeping the environment acidic enough to suppress harmful organisms. When estrogen levels drop after menopause, Lactobacillus populations decline, the protective acidity weakens, and disease-causing bacteria find it easier to colonize.
Research has confirmed that urinary estrogen levels are positively correlated with the abundance of Lactobacillus in postmenopausal women who have no history of UTIs. Studies dating back to 1993 have shown that vaginal estrogen therapy can restore Lactobacillus populations and reduce the rate of recurrent infections. A more recent randomized clinical trial confirmed a significant reduction in recurring UTIs among postmenopausal women using vaginal estrogen therapy compared to placebo.
Diabetes and High Blood Sugar
People with diabetes face a higher risk of UTIs, partly because of what happens when blood sugar spills into the urine. Normally, urine contains very little glucose. But when blood sugar runs high, glucose passes through the kidneys and into the urine, creating an environment where bacteria thrive. Research shows that E. coli exposed to glucose-rich urine shifts its metabolism to feed directly on that sugar, fueling faster growth.
Diabetes can also damage the nerves that control the bladder over time. When the bladder doesn’t empty completely, residual urine sits stagnant, giving bacteria more time to multiply before being flushed out.
Blockages and Structural Problems
Anything that prevents urine from draining normally raises the risk of infection. Kidney stones can partially or completely block a ureter, trapping urine above the obstruction. That stagnant urine becomes a breeding ground for bacteria. In men, an enlarged prostate can compress the urethra and make it difficult to fully empty the bladder, creating the same problem.
Obstruction is a universally recognized risk factor for UTIs, and when infection develops alongside a blockage, it tends to be more serious. Prompt drainage of the affected kidney in these cases can prevent permanent damage and, in severe situations, can be life-saving.
Fungal UTIs
Candida albicans, the same yeast responsible for most vaginal yeast infections, is the most common cause of fungal UTIs. These infections are far less common than bacterial UTIs and typically occur in people with specific risk factors: prolonged antibiotic use, diabetes, immunosuppression (including HIV/AIDS), catheter use, or extended hospital stays. In healthy people, Candida lives harmlessly on the skin and in the vaginal and digestive tracts. It only becomes a problem when the immune system is weakened or when antibiotics wipe out competing bacteria and allow the yeast to overgrow.
Why UTIs Keep Coming Back
Recurrent UTIs are common. About 24% of college-aged women who get a first UTI experience another one within six months. In a large study of over 374,000 women, roughly 14.5% met the clinical definition for recurrent UTIs, meaning at least two infections within six months or three within a year.
Several factors drive recurrence. The ability of E. coli to hide inside bladder cells means that even after symptoms clear and a course of antibiotics finishes, dormant bacteria can re-emerge. Postmenopausal hormonal changes create ongoing vulnerability. Anatomical factors don’t change over time, so someone whose anatomy puts them at higher risk will remain at higher risk. And behavioral patterns, like frequency of sexual activity, continue to play a role. Recurrent UTIs aren’t a sign that something was done wrong during treatment. They reflect the biology of how these infections establish and persist.
How a UTI Is Confirmed
When you have UTI symptoms, a urine sample can reveal chemical and microscopic signs of infection. Two key markers on a basic urine dipstick are leukocyte esterase (a sign of white blood cells fighting infection) and nitrites (produced when certain bacteria break down chemicals in urine). Of the two, leukocyte esterase is the more reliable predictor of an actual infection.
Under a microscope, white blood cell counts offer additional clarity. A threshold of 10 white blood cells per high-power field is considered a practical cutoff: it catches about 81% of true infections while filtering out nearly half of negative samples. If results are unclear or infections keep returning, a urine culture identifies the exact bacteria involved and which antibiotics will work against it.