Urinary Tract Infections

Everything you need to know about how to prevent UTIs

Does cranberry juice really help? And what’s the deal with swimsuits? Here’s expert advice on all that—and more!
A woman with long black hair in braids is wearing a sports top while drinking from a water bottle with her eyes closed

Key Points:

  1. Urinary tract infections (UTIs) can be prevented by practicing good hygiene when using the bathroom, peeing after sex, staying hydrated and avoiding products that can irritate the urinary system. 
  2. UTI prescription antibiotics can help most people clear infections in just a few days.
  3. Other UTI medicines and supplements may help prevent infections in some people who experience frequent UTIs.

The urinary system naturally flushes out bacteria through urination (peeing). But sometimes, this process isn’t enough. Bacteria can travel up through the urinary tract and cause an uncomfortable urinary tract infection (UTI).

If you’re experiencing painful urination (dysuria) or have noticed cloudy urine or bloody urine while you go, you’re not alone! UTIs are so common that up to 60% of people with female anatomy will develop a UTI at least once in their lifetime. Other conditions—like pregnancy, diabetes or catheter use—can make UTIs more likely.

Fortunately, some simple steps can help you prevent future UTIs. Here’s why UTIs come back and which healthy habits can keep them at bay. Plus, how to get antibiotics for a UTI online with some help from Dr. B.

What to do when a UTI keeps coming back

Antibiotic UTI treatment clears up most simple infections quickly. But even if you treat a UTI, there's a chance it may come back. Some people suffer from repeat UTIs (also called recurrent UTIs). This is so common that almost 30% of people who develop a UTI will have another infection in the next 6 months!

If you have recurrent UTIs, seeing a healthcare provider is essential. An underlying condition may contribute to your UTIs, like diabetes, structural changes to the urinary anatomy or a problem with your immune system. There may also be certain medications that can help make recurrent UTIs less likely.

How to prevent a UTI

UTIs are responsible for approximately 7 million doctor visits each year. Even though they’re very common, UTIs can still cause many problems.

Thankfully, several steps can minimize the risk of developing a UTI. Follow these practices to help flush bacteria out of the urinary system and prevent infection.

  • Drink plenty of fluids—particularly water—to encourage your body to urinate frequently.
  • Wipe from front to back after using the bathroom. This helps keep bacteria from the anus and vagina away from the urethra.
  • Pee immediately after sex—and empty your bladder fully.
  • Avoid products that can irritate the urinary system. This includes douches and deodorant sprays that can irritate the delicate lining of the vagina and urethra.
  • Avoid tight-fitting underwear or wet swimsuits. These won’t cause a UTI by themselves. But a warm, moist environment can encourage bacteria to grow around the urethra.
  • Choose a birth control method that won’t irritate urinary or vaginal tissue. Spermicides and diaphragms are both linked to an increased risk of UTIs.

There is emerging evidence that other treatments can help people who experience frequent UTIs. This includes taking a low-dose antibiotic after sex—or even every day.

Does cranberry juice prevent UTIs?

Some research indicates that cranberry makes it harder for E. coli, the most common cause of UTIs, to stick to the walls of the urinary system. But the scientific evidence on whether or not cranberry juice can help prevent a UTI is mixed.

Cranberry juice has a very acidic taste and juice cocktails are also high in sugar. It can cause some mild gastrointestinal issues like nausea and diarrhea. And there is some evidence that it can interact with blood thinner medications. (Warfarin in particular). Because of the risk of side effects, sticking to water may be a better option for people looking to reduce their risk of UTIs.

If you decide to try cranberry juice, the most common uses include drinking 8-10 oz of juice cocktail that contains 25% cranberry juice daily. Or you can try UTI treatment over-the-counter with cranberry pills or tablets containing 600 to >1,200 mg/day per day, divided into 2 or 3 doses daily. Look for tablets that also contain Vitamin C or E—these prevent the compounds in cranberries from breaking down when exposed to air or light.

Before taking cranberry juice or supplements, to talk to your healthcare provider to make sure it’s a safe option for you.

Banner advertising Dr. B's services for UTI treatments

Trusted UTI treatments—online!

UTI symptoms can be very disruptive. Fortunately, a range of UTI pills and antibiotic treatment options can clear up infections fast. Dr. B can help you set up a treatment plan to get UTI antibiotics online through our virtual health platform!

To start, take our online health assessment. It’s only $15 for paying patients and we offer a No-Cost Care program for those who financially qualify. A licensed medical provider will review your health history and current symptoms. If they determine that an online UTI prescription medication is appropriate, they’ll send it to your chosen local pharmacy. That’s it!


Bergamin, P. A., et al. (2017). Non-surgical management of recurrent urinary tract infections in women. Translational Andrology and Urology.

Hisano, M., et al. (2012). Cranberries and lower urinary tract infection prevention. Clinics.

Imam, T. H. (2022). Bladder infection. Merck Manual Commercial Version.

Imam, T. H. (2022). Kidney infection. Merck Manual Commercial Version.

Imam, T. H. (2022). Overview of urinary tract infections. Merck Manual Commercial Version.

Imam, T. H. (2022). Urethritis. Merck Manual Commercial Version.

Medina, M., et al. (2019). An introduction to the epidemiology and burden of urinary tract infections. Therapeutic Advances in Urology.

McCollum, B. J., et al. (2020). PURL: Can drinking more water prevent urinary tract infections?. The Journal of Family Practice.

Plüddemann, A. (2019). Can drinking more water prevent urinary tract infections? The evidence says yes. BMJ Evidence-Based Medicine.

Urology Care Foundation. (2016). Take Steps to Avoid a UTI this Summer.

The American College of Obstetricians and Gynecologists. Urinary tract infections (UTIs).

The National Center for Complementary and Integrative Health. Cranberry.

Sign up for the free Dr. B newsletter for a weekly report on the latest in healthcare + research-based advice for staying healthy and mentally well.

Related articles