How Long Does Bactrim Stay In Your System?

Bactrim is a combination antibiotic consisting of trimethoprim and sulfamethoxazole. It helps fight bacterial infections but can also cause some unpleasant side effects.

Depending on how severe these side effects may be, you may choose to discontinue this medication after talking to your doctor, but your side effects might not go away until Bactrim is out of your system.

As for how long Bactrim stays in your system, it remains for around five days after your last dose, although various factors can modify this length. Still, if your symptoms do not improve within a few days after stopping Bactrim, reach out to a doctor. 

Table of Contents

What Is Bactrim?

Bactrim is the brand name for the combination of sulfamethoxazole/trimethoprim, which are both antibiotics responsible for treating different types of bacterial infections. These antibiotics work together to block two steps in the production of nucleic acids and proteins bacteria need to survive. 

Bactrim is usually taken in doses every twelve hours, and the length of treatment varies based on your infection and its severity, but it may span anywhere from 3 to 14 days. It is also available in double strength tablets as Bactrim DS.


Bactrim is used to treat bacterial infections such as:

  • urinary tract infections (UTIs)
  • ear infections
  • traveler’s diarrhea
  • pneumocystis jiroveci pneumonia
  • shigellosis

Of note, some of the above illnesses can result from bacterial or viral infections. As an antibiotic, Bactrim will only be effective if the cause of the infection is bacterial. 

Side Effects

Like most antibiotics, some of the most common side effects of Bactrim revolve around stomach upset, with diarrhea, in particular, a common side effect, along with nausea, vomiting, or loss of appetite. 

Additionally, Bactrim can make your skin more sensitive to sunlight, which can cause you to sunburn more easily. As such, wearing protective clothing when outside, using sunscreen, and avoiding sunlight or tanning beds when possible is recommended. 

Some people may be allergic to Bactrim, with signs of this including coughing, hives, shortness of breath, chest pain, or swelling in the face or throat. If you experience any of these symptoms, seek emergency medical attention. f

Bactrim may also cause a severe skin reaction with symptoms that include sore throat, fever, skin pain, burning eyes, or a purple or red rash with peeling skin and blisters. Again, if you experience any of these symptoms, seek medical attention. 

How Long Does Bactrim Stay In Your System?

How long Bactrim stays in your system depends on its half-life. Because Bactrim is composed of two different drugs, we need to look at the half-life for each to see the maximum amount of time the drug will remain in your body. 

The half-life of sulfamethoxazole is 10 hours, and the half-life of trimethoprim can range from 8-10 hours. Even though Bactrim is a combination drug, these half-lives don’t add onto each other as both drugs begin breaking down at the same time. So, the maximum half-life would remain 10 hours, and wouldn’t add up to 20 hours.

Now that we know the half-life of Bactrim, we can estimate how long it will stay in your system. Since it generally takes a drug 5-6 half-lives to be entirely removed from the body, it can take 50-60 hours before Bactrim is completely out of your body after your last dose or around 5 days. 

While this is the average amount of time that Bactrim will stay in your system, certain factors can influence it. For example, those who are older often keep drugs in their system for longer. Diet and weight can also influence how long a medicine remains in your system.

Along these same lines, if you have certain medical conditions that influence how well your body can clear out medication, such as kidney disease, it will likely take longer until the drug is entirely out of your system. 

How Long Do the Side Effects of Bactrim Last After Your Last Dose?

Knowing that Bactrim can stay in your system for around 5 days (sometimes more, sometimes less), it’s natural to wonder just how long you may experience Bactrim’s side effects even after you stop taking the medication or have completed your course of treatment. 

In general, Bactrim’s side effects should improve within a few days or up to a week after you stop taking it. 

However, many things can influence how long you may experience side effects, such as your overall health, the side effects you are experiencing, and the dosage of the medication that you are taking. 

Looking at each side effect, those such as nausea and vomiting generally go away within a few days, and taking Bactrim with food can further alleviate them. Once you stop taking Bactrim, these side effects usually go away quickly. 

However, other side effects may last longer. For example, those who develop a skin rash from Bactrim can see variations in how long it lasts based on the rash’s severity and cause. 


How long does Bactrim stay in your system after the last pill?

Both components of Bactrim, trimethoprim and sulfamethoxazole, have half-lives of up to 10 hours. Since a drug remains in the body for 5 to 6 half-lives, Bactrim generally stays in your system for 5 days after you take the last pill. However, some factors can affect how long it stays in your system, such as your overall health, age, or the presence of any metabolic disorders/conditions. 

When to See a Doctor?

If you are taking Bactrim and notice the development of any unpleasant side effects, especially any that make you want to discontinue the medication, reach out to a healthcare provider first. They may be able to offer advice to lessen the side effects, such as taking Bactrim with food to relieve nausea or staying hydrated and avoiding spicy and greasy food to improve diarrhea. 

However, if you notice any severe skin reactions, talk to a doctor immediately:

  • peeling
  • blistering
  • skin rash
  • itching
  • loosening skin
  • ulcers
  • sores
  • red skin lesions
  • white spots on your lips or mouth

There is also a potential risk of allergic reaction with Bactrim, with symptoms such as difficulty breathing, itching, swelling of the throat, tongue, or mouth, and chest pain. If you experience any of these symptoms, call a doctor or visit the emergency room. 

Bactrim may also cause liver problems in some people. Again, seek immediate medical attention if you have any of the following symptoms:

  • lightening stool
  • darkening urine
  • jaundice (yellowing of the skin or eyes)
  • stomach pain

Key Takeaways

Bactrim is a combination antibiotic that consists of sulfamethoxazole/trimethoprim. These two antibiotics work together to treat a range of bacterial infections. Unfortunately, like most antibiotics, Bactrim can have some side effects that generally last as long as you take it. For example, it can make your skin more sensitive to sunlight, so staying out of the sun is recommended as long as Bactrim is in your system.

This raises questions regarding how long Bactrim remains in your system, but generally, it stays in your system for around 5 days after your last dose. Knowing this information is essential for monitoring side effects and seeking medical attention if they do not go away after a few days. 


Content on the DrHouse website is written by our medical content team and reviewed by qualified MDs, PhDs, NPs, and PharmDs. We follow strict content creation guidelines to ensure accurate medical information. However, this content is for informational purposes only and not a substitute for professional medical advice, diagnosis, or treatment. For more information read our medical disclaimer.

Always consult with your physician or other qualified health providers about medical concerns. Never disregard professional medical advice or delay seeking it based on what you read on this website.

If you are experiencing high fever (>103F/39.4C), shortness of breath, difficulty breathing, chest pain, heart palpitations, abnormal bruising, abnormal bleeding, extreme fatigue, dizziness, new weakness or paralysis, difficulty with speech, confusion, extreme pain in any body part, or inability to remain hydrated or keep down fluids or feel you may have any other life-threatening condition, please go to the emergency department or call 911 immediately.



on your schedule

Skip the unnecessary waiting room,
see a board-certified clinician now.

Start an Online Visit
Available in 50 states. No insurance needed.
Screenshot of DrHouse Mobile App: Virtual Doctor Appointment in Progress

Prescriptions as needed
Renew or get a new Rx.

On-demand virtual visits
See a physician 24/7.

24/7 care support
We are here to help you.

  • 1

    Download the DrHouse app.
    Set up your free account in a minute.

  • 2

    Start a visit with an online doctor. Wait time is less than 15 minutes.

  • 3

    Get an Rx from your preferred pharmacy. Pick up a Rx nearby or get it delivered to you.

Download our app
Image of a doctor wearing a white lab coat, representing the DrHouse telehealth service