How Do You Get a Kidney Infection: Causes & Risks

A kidney infection almost always starts as a bladder infection that travels upward. Bacteria enter the urethra, multiply in the bladder, and then climb through one or both ureters into the kidneys. This ascending route accounts for the vast majority of cases, with E. coli responsible for 70 to 95% of uncomplicated kidney infections.

How Bacteria Travel From the Bladder to the Kidneys

Your urinary tract is designed to flush bacteria out. The ureters, the two tubes connecting your kidneys to your bladder, contract in waves to push urine downward, and the constant flow makes it difficult for bacteria to swim upstream. But certain strains of E. coli have evolved tools to overcome this. They produce tiny hair-like structures on their surface that grip the walls of the urinary tract, anchoring themselves against the flow of urine. Combined with whip-like tails that propel them forward, these bacteria can gradually work their way from the bladder into the ureters and up to the kidneys.

Even more remarkably, these bacteria can actually slow down the muscular contractions of the ureters themselves. By interacting with the cells lining the ureter walls, they interfere with the calcium signals that drive those contractions, essentially weakening the body’s built-in flushing mechanism. Once bacteria reach the kidney, they switch to a different set of surface grippers that latch onto kidney cells directly.

This is why a bladder infection (lower UTI) that goes untreated can escalate quickly. There’s no precise timetable for how long it takes a bladder infection to reach the kidneys, but the progression can happen fast, which is why treating a UTI promptly matters.

Who Is Most at Risk

Anything that slows or blocks the normal flow of urine gives bacteria more time to establish themselves. Kidney stones are a common culprit: a stone lodged in a ureter creates a dam that traps urine and bacteria behind it. Enlarged prostate tissue in men can have a similar effect by making the bladder harder to empty completely. Pregnancy shifts the position of the ureters and can compress them, which is one reason pregnant women are screened for urinary infections even without symptoms.

A structural condition called vesicoureteral reflux, where urine flows backward from the bladder toward the kidneys, is a major risk factor in children. The valve between the ureter and bladder doesn’t close properly, so bacteria-laden urine gets pushed in the wrong direction. An estimated 30 to 50% of children who develop a UTI turn out to have this condition. In many cases there are no symptoms until a kidney infection actually develops.

Urinary catheters are another significant risk. About 75% of UTIs that develop in hospitals are linked to catheter use, and the longer a catheter stays in place, the higher the risk. The tube provides a direct path for bacteria to enter the bladder, bypassing the body’s normal defenses.

Women get kidney infections more often than men, largely because the female urethra is shorter, giving bacteria a shorter distance to travel to reach the bladder. Sexual activity, a history of recurrent UTIs, and a weakened immune system (from diabetes, for example) all raise the odds further.

The Less Common Route: Through the Blood

In rare cases, a kidney infection develops without a bladder infection at all. Instead, bacteria or fungi circulating in the bloodstream from an infection elsewhere in the body settle in kidney tissue. This “descending” route is more commonly associated with Staphylococcus bacteria and certain fungal organisms like Candida. People with compromised immune systems or those who have an active infection in another part of the body, such as the heart or bones, are the most likely to develop a kidney infection this way.

What a Kidney Infection Feels Like

A bladder infection and a kidney infection share some symptoms, like burning during urination and frequent urges to go. But a kidney infection adds a distinct set of warning signs that feel noticeably different. Flank pain, a deep ache on one or both sides of your lower back just below the ribs, is the hallmark. Many people also develop a fever, sometimes with chills, nausea, or vomiting. The urine may look cloudy or smell unusually strong.

The key distinction is that a bladder infection generally stays localized: uncomfortable but manageable. A kidney infection is a systemic illness. You feel sick in your whole body, not just when you use the bathroom. If bacteria from the kidneys spill into the bloodstream, the infection can become dangerous, so a sudden fever alongside urinary symptoms is a signal to get medical attention quickly.

How a Kidney Infection Is Diagnosed

Diagnosis typically starts with a urinalysis, a simple urine test that checks for white blood cells (a sign your body is fighting infection) and blood. A urine culture is usually ordered alongside it to identify the specific type of bacteria and determine which antibiotics will work against it. Blood tests may be added if the infection appears severe, both to check for bacteria in the bloodstream and to assess how well your kidneys are functioning.

Imaging comes into play when the infection doesn’t respond to initial treatment or when a doctor suspects an underlying structural problem. A CT scan, ultrasound, or MRI can reveal kidney stones, blockages, abscesses, or anatomical abnormalities like vesicoureteral reflux that may have set the stage for infection in the first place.

What Recovery Looks Like

Antibiotics are the standard treatment, and most people with an uncomplicated kidney infection start feeling better within two to three days of beginning a course. The full course typically runs one to two weeks. Mild to moderate cases are usually managed at home with oral antibiotics and plenty of fluids. More severe infections, especially those involving high fever, vomiting, or signs that bacteria have entered the bloodstream, may require a hospital stay for intravenous treatment until symptoms stabilize.

If a structural issue like a kidney stone or blockage is contributing to the infection, that underlying problem needs to be addressed to prevent recurrence. People who get repeated kidney infections are sometimes evaluated with imaging to look for anatomical causes that can be corrected.