A kidney infection is treated with antibiotics, and most people can take them at home in pill form. The standard course lasts 5 to 14 days depending on the antibiotic used, and first-line options have greater than 90% clinical success rates when the bacteria causing the infection are susceptible. Severe cases require hospitalization for intravenous antibiotics. The key is starting treatment quickly, because a kidney infection that spreads to the bloodstream can become life-threatening.
How Kidney Infections Are Diagnosed
If you show up with classic symptoms like flank pain, fever, and painful urination, your doctor will typically order two tests. A urinalysis checks your urine for white blood cells (a sign your body is actively fighting a bacterial infection) and for blood. A urine culture then identifies the specific bacteria causing the infection and, critically, which antibiotics that bacteria is vulnerable to. This culture can take a couple of days to come back, so your doctor will usually start you on antibiotics right away based on the most likely cause and adjust later if needed.
In more complicated cases, imaging like a CT scan or ultrasound may be ordered to check for blockages, kidney stones, or abscesses that could be making the infection worse or harder to clear.
Antibiotic Treatment at Home
Most uncomplicated kidney infections are treated on an outpatient basis with oral antibiotics. The two main first-line options are fluoroquinolones and a combination antibiotic called trimethoprim/sulfamethoxazole (often known as TMP-SMX or Bactrim). The treatment length varies by drug: fluoroquinolone courses typically run 5 to 7 days, while TMP-SMX requires a longer course of about 14 days.
Not every antibiotic that works for a bladder infection works for a kidney infection. Some common bladder infection drugs, like nitrofurantoin and fosfomycin, don’t reach high enough concentrations in kidney tissue to be effective there. Certain other antibiotics are considered inferior for kidney infections and aren’t recommended as first-line treatment.
One wrinkle: antibiotic resistance. If the bacteria in your area are likely to be resistant to the prescribed antibiotic (a threshold doctors generally set at above 10% local resistance), your doctor may give you a one-time injection of a stronger, broader-spectrum antibiotic at your first visit while waiting for your urine culture results to confirm which oral antibiotic will work best.
When Hospital Treatment Is Needed
Some kidney infections are too severe to manage at home. You’re more likely to need hospitalization if you can’t keep fluids or pills down due to vomiting, if you have a high fever that isn’t responding to treatment, if you show signs of sepsis (such as very fast heart rate, confusion, or dangerously low blood pressure), or if you have underlying conditions like diabetes, kidney disease, or a weakened immune system that make complications more likely.
In the hospital, antibiotics are delivered intravenously so they reach effective levels in the blood faster. Once your fever breaks and you’re able to eat and drink normally, you’ll typically be switched to oral antibiotics to finish the course at home.
Treatment During Pregnancy
Kidney infections during pregnancy deserve special attention. They occur most frequently in the second trimester and are one of the most common medical reasons for hospitalization during pregnancy. The stakes are higher because serious complications, including sepsis and acute respiratory distress syndrome, can develop. For this reason, pregnant individuals with a kidney infection are generally treated more aggressively and monitored more closely than other patients.
As with non-pregnant patients, nitrofurantoin and fosfomycin should be avoided because they can’t reach adequate levels in kidney tissue. The specific antibiotic chosen will depend on what’s safe for the pregnancy and what the urine culture shows.
Managing Pain and Discomfort
Kidney infections can cause significant pain in the back and side, along with fever, chills, nausea, and a burning sensation when urinating. While antibiotics tackle the underlying infection, you’ll likely need something for the pain and fever in the meantime.
Acetaminophen (Tylenol) is generally the safest over-the-counter option. NSAIDs like ibuprofen (Advil, Motrin) and naproxen (Aleve) reduce the amount of blood flowing through the kidneys, which can lead to acute kidney injury or worsen existing kidney disease, particularly at higher doses or with prolonged use. If you have chronic kidney disease, it’s best to avoid NSAIDs entirely. Even without pre-existing kidney problems, acetaminophen is the more cautious choice when your kidneys are already under stress from an active infection.
Staying well-hydrated helps flush bacteria from the urinary tract and supports recovery. A heating pad on your back or abdomen can also help ease flank pain.
What Recovery Looks Like
Most people start to feel noticeably better within 48 to 72 hours of starting the right antibiotic. Fever is often the first symptom to improve. Flank pain and urinary symptoms tend to linger a bit longer but should steadily improve over the first few days.
It’s important to finish the entire course of antibiotics, even once you feel better. Stopping early allows surviving bacteria to regroup, potentially leading to a relapse or antibiotic-resistant infection. If your symptoms aren’t improving after two to three days of treatment, contact your doctor. This could mean the bacteria are resistant to the antibiotic you were prescribed, and a switch may be needed based on your culture results.
Risks of Delayed or No Treatment
A kidney infection is not something that resolves on its own. Left untreated, the bacteria can spread from the kidneys into the bloodstream, a condition called urosepsis. This is a medical emergency. Complications of urosepsis include organ damage, organ failure, septic shock, and death. Even infections that don’t progress to sepsis can cause permanent kidney scarring or abscess formation if treatment is delayed.
The progression from a simple urinary tract infection to a kidney infection to sepsis can happen relatively quickly, which is why kidney infection symptoms like high fever, severe flank pain, and vomiting warrant prompt medical attention rather than a wait-and-see approach.

