Home What Is Cephalexin?

What Is Cephalexin?

Uses, Side Effects, Dosage & FAQs (2026 Guide)

Written by: Mariah Powers Medically reviewed by: Ashley Robinson, PharmD Last Updated:

Cephalexin is a prescription-strength antibiotic medication that belongs to the cephalosporin drug class. It is primarily used to treat bacterial infections in skin, bones, ears, and respiratory and urinary tracts.

While considered effective against bacterial infections, cephalexin does not treat viral infections like the flu or COVID-19.

Providers typically prescribe the drug for a short-term duration of one to two weeks. Most people tolerate the drug well, but some side effects can occur during the treatment course.

How It Works

Cephalexin is bactericidal, meaning it kills bacteria directly rather than simply inhibiting their growth. Cephalexin targets the enzymes that produce peptidoglycan, a mesh-like material forming the bacteria’s cell walls. 

Without these enzymes, the peptidoglycan weakens and the cell walls eventually collapse from internal pressure, killing the bacteria.

Quick Facts
Common Brands Keflex
Drug Class Cephalosporin antibiotic (first-generation)
Generic Status Generic for Keflex
Availability Prescription only

Dosing

Cephalexin is available in different strengths. However, the human body clears this medication quickly, so patients typically require multiple doses per day for the entire treatment course.

  • Standard dose: For most infections, adult patients take 250 mg of cephalexin every 6 hours or 500 mg every 12 hours.
  • Severe infections: Stubborn infections may require a larger dose. Providers may prescribe up to 4 grams per day to fight deep-seated infections.
  • Duration: A typical cephalexin treatment course runs 7 to 14 days. Although patients may feel better within 3 days, standard guidelines advise to complete the entire course unless instructed otherwise by a medical provider.
  • Administration: Per standard guidelines, you can take cephalexin with or without food. However, a meal or snack with the medication can reduce the risk of an upset stomach.

Note: Dosing information is educational only. Your prescribing physician will determine your specific dose based on your individual health needs. Always follow your healthcare provider’s instructions for exact dosing.

Uses

FDA-Approved Uses

Cephalexin is FDA-approved to treat the following:

  • Skin and skin structure infections, including Staphylococcus aureus and Streptococcus pyogenes
  • Respiratory infections caused by susceptible bacteria, such as pneumonia or bronchitis
  • Urinary tract infections, including cystitis (bladder infection) and prostatitis
  • Middle ear infections (otitis media)
  • Bacterial bone infections (osteomyelitis)

Off-Label Uses

You may see cephalexin prescribed for uses that are not “FDA-approved.” This is a common and legal practice called “off-label” prescribing, where a doctor uses their clinical judgment to prescribe a drug for a different (but well-researched) purpose.

Common off-label uses for cephalexin currently found in clinical research and practice include:

  • Dental infections: Cephalexin may be used to treat tooth abscesses or serve as a prophylaxis prior to dental procedures for people with preexisting heart conditions.
  • Endocarditis prophylaxis: Patients may be prescribed cephalexin to prevent heart valve infections during surgery or dental procedures.
  • Acne vulgaris: Cephalexin has shown to be effective for some people with inflammatory acne who have not had success with first-line topical treatments.

Side Effects


Patients generally tolerate cephalexin well, but the drug can interact with natural bacterial flora in the body and cause side effects.

Common Side Effects

  • Nausea, vomiting, and stomach pain
  • Diarrhea
  • Headache
  • Dizziness and fatigue
  • Vaginal yeast infections

Serious Side Effects

Serious side effects are rare, but it’s important to know what to look for if they do occur. Serious side effects that can occur from taking cephalexin include:

  • C. difficile-associated diarrhea: This type of watery and/or bloody diarrhea can occur after taking cephalexin. It may be accompanied by severe stomach cramps or fever. This is considered a life-threatening condition, so it is advised to contact your provider immediately if you notice any symptoms.
  • Skin Reaction: While rare, Stevens-Johnson syndrome and other skin reactions can occur after taking cephalexin. Possible symptoms include redness, blistering, or peeling.
  • Seizures: People who take high doses of cephalexin and/or have underlying kidney disease are at a higher risk of experiencing seizures after taking cephalexin.
  • Hemolytic anemia: Cephalexin has been linked to hemolytic anemia, a rare blood disorder that causes red blood cells to be destroyed faster than they are created. Symptoms include jaundice of the eyes and skin and extreme weakness.
  • Severe allergic reaction: Cephalexin may cause anaphylaxis in people who are allergic to one or more of its ingredients.

Call your doctor immediately if you experience any concerning or prolonged symptoms.

Pharmacist Tips

The “Rotten” Smell Is Normal

Many people who take cephalexin liken the drug’s smell to rotten eggs due to its sulfur content. If you notice a foul or pungent smell coming from your cephalexin container, that does not necessarily mean the medication has gone bad or expired.

Finish The Treatment Course

It is recommended to complete your entire cephalexin treatment course even if you notice symptoms tapering off within a few days. Finishing the course ensures the strongest, most resilient bacteria will be destroyed.

Probiotics May Help

Some providers may recommend taking cephalexin with active-culture yogurt. This probiotic-laden snack can help reduce the risk of diarrhea and yeast infections, two common side effects from taking the drug.

Take Caution With Kidney Health

Before taking cephalexin as prescribed, it is advised to speak to your doctor if you have kidney disease. Higher doses of the drug can harm the kidneys and a preexisting kidney condition may compound this issue.

Swallow The Capsule Whole

It is not recommended to crush or chew the cephalexin capsules because this can interfere with how your body absorbs the medication. If you have trouble swallowing, a cephalexin oral suspension may be available.

Drug Interactions

Cephalexin can interact with a wide range of medications. Known interactions with cephalexin include:

  • Metformin: Cephalexin increases the effects of metformin, a medication used to stabilize blood sugar. This interaction can cause blood sugar levels to drop significantly.
  • Probenecid: Probenecid, a gout medication, slows down the removal of cephalexin from the kidneys. This can increase cephalexin’s side effects.
  • Other antibiotics: Mixing antibiotics unless under direct instruction from your doctor is not recommended. This can decrease the efficacy of one or more of the antibiotics, and possibly lead to toxicity.
  • Birth control: Although it is generally safe to use cephalexin while taking oral birth control, your provider may recommend a backup method because antibiotics can interfere with estrogen absorption.
  • Alcohol: There is no direct interaction between cephalexin and alcohol, but alcohol can cause dehydration and weaken the immune system, making it harder to fight the infection.

Always give your doctor and pharmacist a complete list of all your medications, vitamins, and supplements to check for potential interactions.

FAQs

Why does my cephalexin smell like sulfur or rotten eggs?

The “rotten egg” smell is normal for cephalexin, which contains sulfur in its chemical structure. The odor is a natural byproduct of the medication, not an indication that the drug has expired or “gone bad.”

Can I take cephalexin if I am allergic to penicillin?

Whether you can take cephalexin if you are allergic to penicillin depends on the severity of your allergy. Roughly 1% to 10% of people who are allergic to penicillin may also react to cephalosporin drugs. People who have had life-threatening reactions to penicillin are advised to avoid taking cephalexin except under close medical supervision.

Does cephalexin treat MRSA (methicillin-resistant Staphylococcus aureus)?

Generally, cephalexin is not effective against and does not treat MRSA. Other antibiotics like Bactrim or doxycycline are usually preferred for MRSA treatment.

Can I drink alcohol while taking cephalexin?

Yes, you can drink alcohol while taking cephalexin, but your provider may recommend light to moderate drinking, or abstaining entirely from alcohol, during your cephalexin treatment course.

Alcohol dehydrates the body and can weaken the immune system, making it harder to battle the bacterial infection.

Does cephalexin cause yeast infections?

Cephalexin can make you more prone to yeast infections, though it does not cause them. The drug kills both harmful and protective bacteria, which may allow yeast to grow when unchecked by the beneficial bacteria that typically keeps it at bay. It is advised to contact your provider if you notice unusual itching or discharge.

Why do I have to take this antibiotic 4 times a day?

Cephalexin is a “time-dependent” medication, meaning it only works when your blood concentration has reached a certain level. Since your kidneys quickly filter out the drug, frequent doses are needed to keep the bacteria at bay.

Does cephalexin work for a tooth infection?

Yes, cephalexin may work to treat a tooth abscess or gum infection. It is commonly prescribed off-label for this purpose. That said, dentists may prefer amoxicillin as first-line treatment unless the patient is allergic to it.

Does cephalexin affect birth control pills?

Most modern research suggests cephalexin does not reduce the effectiveness of oral contraceptives. However, if the drug causes diarrhea or vomiting, this may indicate your body is not fully absorbing the birth control. Many providers recommend a backup barrier method such as condoms.

Is cephalexin effective for a urinary tract infection (UTI)?

Yes, cephalexin can be effective for a UTI and is often prescribed as second-line treatment for this condition. The drug is commonly used for people who cannot take sulfa drugs or macrobid.

Can I take cephalexin with food or milk?

Yes, you may take cephalexin with food or milk because neither interferes with cephalexin being absorbed within your body. A meal or snack is recommended with each dose to prevent nausea and an upset stomach.

Does cephalexin make you sleepy?

Drowsiness is not considered a common side effect of cephalexin. Some people feel fatigued during their cephalexin treatment course, but this may be a reaction to infection rather than the medication.

Can I open the capsule and mix the powder with food?

No, it is not advised to chew or crush the cephalexin capsule. It should be swallowed whole to be appropriately absorbed within the body.

How long does it take for cephalexin to start working?

Many people begin to notice an improvement in their symptoms within 72 hours of beginning their cephalexin course. However, it is recommended that patients finish the entire medication course to ensure the infection is eliminated.

Is cephalexin considered a “strong” antibiotic?

Yes, cephalexin is a broad-spectrum antibiotic and considered “strong” compared to similarly formulated medications. It is bactericidal, meaning it directly kills bacteria instead of simply inhibiting their growth.

Can I take ibuprofen or Tylenol with cephalexin?

Yes, you can take ibuprofen or Tylenol with cephalexin as long as your doctor approves. These drugs do not have significant interactions with cephalexin, though some pain relievers may cause flare-ups for people with preexisting kidney issues.

What is the difference between cephalexin and amoxicillin?

Cephalexin and amoxicillin are both bactericidal antibiotics, but they belong to different drug classes. Cephalexin is a cephalosporin, whereas amoxicillin is a penicillin-type antibiotic.

The latter is typically prescribed to treat respiratory infections, and the former is usually prescribed to treat skin, bone, middle ear, and urinary tract infections.

Comparable Medications

Cephalexin, Cefadroxil, Cefdinir, Amoxicillin, Amoxicillin/Clavulanate, Sulfamethoxazole-Trimethoprim, Clindamycin, Doxycycline, Nitrofurantoin, or Ciprofloxacin?

Cephalexin is a bactericidal, broad-spectrum antibiotic commonly used to treat skin, bone, ear, and urinary tract infections caused by susceptible bacteria. Your doctor may recommend an alternative to cephalexin based on factors like age and medical history. Common cephalexin alternatives include:

This drug, the generic for Augmentin, combines penicillin with a beta-lactamase inhibitor to fight particularly resistant bacteria. However, it may carry a higher risk of triggering a penicillin allergy compared to cephalexin.


The generic for Bactrim, this sulfa drug is often used to treat UTIs, ear infections, pneumonia, and MRSA-related cellulitis. It may be prescribed over cephalexin for people who are allergic to penicillin.


The generic for Cleocin, clindamycin is commonly prescribed to treat skin and soft tissue infections. Clindamycin is typically prescribed for treating MRSA over cephalexin.


Doxycycline is a tetracycline drug often used to treat tick-borne illnesses, acne, and MRSA skin infections. However, cephalexin is usually preferred for treating pregnant patients as doxycycline may impact fetal bone growth and tooth staining.


The generic for Macrobid, this specialist antibiotic concentrates in the bladder and is a treatment for UTIs. It is less effective at treating infections outside of the bladder.


Ciprofloxacin is a high-strength fluoroquinolone antibiotic typically reserved for complicated UTIs or kidney infections.

We Have Cephalexin in Stock. Get Yours Today!

Important: Information on this page is for educational purposes only. Prescribing decisions are made by independent, licensed providers. TelyRx operates technology-enabled pharmacies and a telehealth platform that connects patients with board-certified licensed providers. Prescriptions, when provider-approved and issued, are filled and shipped by TelyRx-affiliated pharmacies. We do not employ physicians or make prescribing decisions. Learn more about our editorial standards here.