Log in
First-generation cephalosporin

Cefalexin

Cefalexin (cephalexin in US) is a first-generation cephalosporin antibiotic with excellent Gram-positive coverage and oral bioavailability. It is commonly used for skin and soft tissue infections, streptococcal pharyngitis, and uncomplicated urinary tract infections. The most testable fact is its coverage spectrum: excellent against Staphylococcus aureus (methicillin-sensitive) and Streptococcus pyogenes, with limited Gram-negative activity.

Drug classFirst-generation cephalosporin (beta-lactam antibiotic)
MechanismInhibits bacterial cell wall synthesis by binding PBPs
Main usesSkin infections, UTIs, streptococcal pharyngitis
Key adverse effectHypersensitivity reactions, GI upset, possible cross-allergy with penicillins
7 min readFor medical studentsUpdated 2026-10-14

Mechanism of action

Cefalexin is a bactericidal beta-lactam antibiotic that inhibits bacterial cell wall synthesis. It binds to penicillin-binding proteins (PBPs) located in the bacterial cell wall, disrupting the final transpeptidation step of peptidoglycan synthesis. This weakens the cell wall and leads to osmotic lysis and cell death, particularly during active bacterial growth.

As a first-generation cephalosporin, cefalexin has a relatively narrow spectrum compared to later-generation agents. It demonstrates excellent activity against Gram-positive cocci, including methicillin-sensitive Staphylococcus aureus (MSSA), Streptococcus pyogenes (group A Streptococcus), Streptococcus pneumoniae, and most strains of Streptococcus agalactiae (group B Streptococcus). It also covers some Gram-negative organisms including Escherichia coli, Proteus mirabilis, and Klebsiella pneumoniae, but has poor activity against Enterococcus, methicillin-resistant Staphylococcus aureus (MRSA), Pseudomonas, and anaerobes.

Cefalexin is resistant to staphylococcal penicillinase but is hydrolyzed by extended-spectrum beta-lactamases (ESBLs) and AmpC beta-lactamases, limiting its effectiveness against resistant Gram-negative bacteria.

High-yield for exams
  • First-generation cephalosporin with excellent MSSA and Streptococcus coverage but no MRSA activity
  • Mechanism: inhibits bacterial cell wall synthesis by binding penicillin-binding proteins (PBPs)
  • Cross-reactivity with penicillins is historically overstated; true rate is 1-3%, highest with severe IgE-mediated reactions
  • Poor CNS penetration makes it unsuitable for meningitis; use third-generation cephalosporins instead
  • First-line oral agent for uncomplicated skin and soft tissue infections caused by MSSA
  • Pregnancy Category B—one of the safest antibiotics in pregnancy
  • Major adverse effect: Clostridioides difficile-associated diarrhea; monitor any patient with diarrhea during or after treatment
  • Requires dose adjustment in renal impairment (CrCl <30 mL/min) to prevent neurotoxicity and seizures

Indications

Cefalexin is FDA-approved for infections caused by susceptible organisms:

Respiratory tract infections

  • Streptococcal pharyngitis and tonsillitis (alternative to penicillin V)
  • Otitis media
  • Community-acquired pneumonia (limited use due to increasing S. pneumoniae resistance)

Skin and soft tissue infections

  • Cellulitis
  • Impetigo
  • Wound infections
  • Abscesses (after drainage)
  • Erysipelas

Urinary tract infections

  • Uncomplicated cystitis caused by E. coli, P. mirabilis, or Klebsiella species
  • Not recommended for pyelonephritis due to poor tissue penetration

Bone and joint infections

  • Osteomyelitis (MSSA)
  • Septic arthritis (susceptible organisms)

Other uses

  • Prophylaxis before dental or surgical procedures in specific cases
  • Streptococcal prophylaxis in patients with history of rheumatic fever

Cefalexin is particularly useful in outpatient settings due to its oral formulation, favorable dosing schedule, and excellent absorption. It is a common alternative in patients with non-severe penicillin allergy.

Pharmacokinetics

Absorption: Cefalexin is well absorbed from the gastrointestinal tract with oral bioavailability of approximately 90-95%. Peak serum concentrations occur 1 hour after oral administration. Food delays absorption but does not significantly reduce bioavailability.

Distribution: The drug is widely distributed to most body tissues and fluids including bone, bile, and pleural fluid. Protein binding is low (10-15%). Cefalexin crosses the placenta and is excreted in breast milk in small amounts. It achieves poor penetration into the central nervous system, even with inflamed meninges, making it unsuitable for meningitis treatment.

Metabolism: Cefalexin undergoes minimal hepatic metabolism. It is excreted primarily unchanged in the urine.

Elimination: Renal excretion via glomerular filtration and tubular secretion accounts for 80-90% of elimination. The elimination half-life is approximately 0.5-1.2 hours in patients with normal renal function. In patients with renal impairment, the half-life is prolonged, requiring dose adjustment when creatinine clearance is below 30 mL/min.

Probenecid competitively inhibits tubular secretion of cefalexin, prolonging its serum half-life and increasing peak concentrations. Dosing follows the product label and must be adjusted for renal function.

Adverse effects

Cefalexin is generally well tolerated, with most adverse effects being mild and self-limiting.

Common adverse effects

  • Gastrointestinal: Diarrhea (most common), nausea, vomiting, dyspepsia, abdominal pain
  • Hypersensitivity: Rash, urticaria, pruritus
  • Vaginal candidiasis: Secondary to disruption of normal flora

Serious adverse effects

  • Hypersensitivity reactions: Anaphylaxis, angioedema, Stevens-Johnson syndrome, toxic epidermal necrolysis (rare)
  • Clostridioides difficile-associated diarrhea: Can range from mild diarrhea to life-threatening pseudomembranous colitis
  • Hematologic: Eosinophilia, thrombocytopenia, neutropenia, hemolytic anemia (rare)
  • Hepatic: Transient elevation in liver enzymes, cholestatic jaundice (rare)
  • Renal: Interstitial nephritis, acute kidney injury (rare)
  • Seizures: Particularly in patients with renal impairment receiving inappropriately high doses

Cross-reactivity with penicillins

Historically, the reported cross-reactivity between penicillins and cephalosporins was estimated at 10%, but recent data suggest the true rate is much lower (1-3% or less). Cross-reactivity is highest in patients with recent, severe, IgE-mediated penicillin reactions. Cefalexin can generally be used cautiously in patients with remote or mild penicillin allergy, but should be avoided in those with documented severe IgE-mediated reactions (anaphylaxis, Stevens-Johnson syndrome).

Laboratory test interference

Cefalexin may cause false-positive results for urine glucose when using copper reduction tests (Clinitest) but not with glucose oxidase methods. It may also cause false-positive direct Coombs test.

Contraindications and warnings

Absolute contraindications:

  • Known hypersensitivity to cefalexin or other cephalosporins
  • History of cephalosporin-associated anaphylaxis

Relative contraindications and warnings:

Penicillin allergy

Use with caution in patients with documented severe penicillin allergy. The risk of cross-reactivity is low but not zero. Avoid in patients with recent anaphylaxis to penicillins.

Renal impairment

Dose adjustment is required when creatinine clearance falls below 30 mL/min. Accumulation can lead to neurotoxicity including seizures. Monitor renal function in elderly patients and those with pre-existing kidney disease.

Gastrointestinal disease

Use with caution in patients with history of inflammatory bowel disease or antibiotic-associated colitis. Clostridioides difficile infection can occur during or after treatment.

Pregnancy and lactation

Pregnancy: Category B (US classification). Animal studies show no fetal harm, and cefalexin is commonly used during pregnancy for appropriate indications. It is considered one of the safest antibiotics in pregnancy.

Lactation: Cefalexin is excreted in breast milk in small amounts. Generally considered compatible with breastfeeding, but monitor the infant for diarrhea, candidiasis, or allergic reactions.

Superinfection

Prolonged use may result in overgrowth of non-susceptible organisms, including fungi. Monitor for secondary infections.

Phenylketonuria

Some oral suspensions contain phenylalanine; use caution in patients with phenylketonuria.

Drug interactions

Cefalexin has relatively few clinically significant drug interactions.

Major interactions

Probenecid: Inhibits renal tubular secretion of cefalexin, increasing serum concentrations and prolonging half-life. This interaction can be used therapeutically to maintain higher antibiotic levels, but dose adjustment may be necessary.

Metformin: Cefalexin may increase metformin serum concentrations by competing for renal tubular secretion, potentially increasing the risk of lactic acidosis. Monitor blood glucose closely.

Anticoagulants (warfarin): Cephalosporins may potentiate the effects of warfarin by suppressing vitamin K-producing gut flora or through direct effects on coagulation. Monitor INR closely when initiating or discontinuing cefalexin in patients on warfarin.

Moderate interactions

Live bacterial vaccines (e.g., typhoid, BCG): Antibiotics may reduce the effectiveness of live bacterial vaccines. Avoid concurrent use when possible.

Oral contraceptives: While theoretically antibiotics could reduce oral contraceptive efficacy by altering gut flora, clinical evidence for this interaction with cefalexin is weak. However, advise patients to use additional contraceptive methods during treatment and for one cycle afterward as a precaution.

Aminoglycosides: Concurrent use may increase the risk of nephrotoxicity. Monitor renal function when using in combination.

Laboratory interactions

Cefalexin may cause false-positive results in urine glucose tests using copper reduction methods and false-positive direct Coombs test, potentially complicating cross-matching for blood transfusions.

Clinical pearls

  • First-line for simple MSSA infections: Cefalexin is the oral antibiotic of choice for uncomplicated skin and soft tissue infections caused by methicillin-sensitive Staphylococcus aureus. It has better staphylococcal coverage than amoxicillin.
  • Not effective for MRSA: Remember that first-generation cephalosporins have no activity against methicillin-resistant Staphylococcus aureus. In communities with high MRSA prevalence, consider alternative agents for empiric treatment of purulent cellulitis.
  • Poor CNS penetration: Never use cefalexin for meningitis, even with susceptible organisms. Third-generation cephalosporins (ceftriaxone, cefotaxime) are required for adequate CSF penetration.
  • Penicillin allergy myth: The historically quoted 10% cross-reactivity between penicillins and cephalosporins is outdated. Current evidence suggests the true rate is 1-3%. Cefalexin can often be used in patients with non-severe penicillin allergy, but avoid in those with recent anaphylaxis.
  • Excellent oral absorption: The high oral bioavailability (>90%) makes cefalexin ideal for step-down therapy from IV cephalosporins in appropriate clinical scenarios.
  • Limited Gram-negative coverage: While cefalexin covers some Gram-negative organisms (E. coli, Proteus, Klebsiella), increasing resistance limits its reliability for complicated UTIs or serious Gram-negative infections. It has no activity against Pseudomonas or Enterobacter.
  • Pregnancy safety: One of the safest antibiotics in pregnancy (Category B), commonly used for group B Streptococcus prophylaxis alternatives, UTIs, and skin infections in pregnant patients with penicillin allergy.
  • Strep pharyngitis alternative: While penicillin V remains first-line for streptococcal pharyngitis, cefalexin is an excellent alternative with similar or better eradication rates and more convenient dosing.
  • Watch for C. difficile: Like all broad-spectrum antibiotics, cefalexin can cause Clostridioides difficile-associated diarrhea. Consider this diagnosis in patients who develop diarrhea during or within 8 weeks after treatment.
  • Renal dosing is essential: The drug is renally cleared, and accumulation in renal impairment can cause neurotoxicity including seizures. Always adjust the dose based on creatinine clearance.
Mnemonic

First-generation cephalosporins remember: '1st generation = 1 main use = Skin (MSSA) and Strep.' They excel at Gram-positive cocci but have limited Gram-negative coverage compared to later generations.

Practice questions

1. A 32-year-old woman presents to the emergency department with a 2-day history of redness, warmth, and swelling of her left lower leg. She reports a small cut from shaving 5 days ago. On examination, there is a 10 cm area of erythema with indistinct borders on the anterior shin, warm to touch, with no purulence or fluctuance. Vital signs are normal. She has a documented history of developing a rash as a child after taking amoxicillin. Which of the following is the most appropriate oral antibiotic for this patient?

Answer: A. This patient has non-purulent cellulitis most likely caused by Streptococcus or methicillin-sensitive Staphylococcus aureus. Cefalexin is the first-line oral agent for this condition and can be used safely in patients with non-severe, remote penicillin allergy (childhood rash), as the true cross-reactivity rate is only 1-3%. Clindamycin would be an alternative, but cefalexin is preferred for non-purulent cellulitis. Vancomycin is IV only and reserved for severe infections or confirmed MRSA.

2. A 65-year-old man with chronic kidney disease (creatinine clearance 25 mL/min) is prescribed cefalexin for a wound infection. Three days into treatment, his family reports he has become increasingly confused and had a brief episode of arm twitching. Vital signs show blood pressure 145/88 mmHg, heart rate 78/min, temperature 37.2°C. Which of the following is the most likely explanation for his symptoms?

Answer: C. Cefalexin is renally cleared and accumulates in patients with impaired kidney function, causing neurotoxicity including confusion and seizures. This patient's CrCl of 25 mL/min requires dose adjustment, which was apparently not done. The temporal relationship and clinical presentation are classic for beta-lactam neurotoxicity. Hypersensitivity reactions typically present with rash or anaphylaxis, not isolated confusion and twitching. C. difficile presents with diarrhea, not primarily neurologic symptoms.

3. A 28-year-old pregnant woman at 24 weeks gestation presents with dysuria and urinary frequency for 2 days. Urinalysis shows 50-100 WBCs/hpf and positive nitrites. Urine culture is pending. She has no known drug allergies. Which of the following is the most appropriate initial antibiotic treatment?

Answer: D. Cefalexin is Pregnancy Category B and is one of the safest antibiotics for treating urinary tract infections during pregnancy. It has good coverage against common uropathogens including E. coli and can be used in all trimesters. Fluoroquinolones (ciprofloxacin) are generally avoided in pregnancy due to concerns about cartilage development. Trimethoprim-sulfamethoxazole is avoided in the first trimester (neural tube defects) and third trimester (kernicterus). Doxycycline causes tooth discoloration and bone abnormalities and is contraindicated in pregnancy.

Frequently asked questions

How does cefalexin work?

Cefalexin is a beta-lactam antibiotic that inhibits bacterial cell wall synthesis by binding to penicillin-binding proteins (PBPs), causing cell lysis and death. As a first-generation cephalosporin, it has excellent activity against Gram-positive cocci including methicillin-sensitive Staphylococcus aureus and Streptococcus species, with limited Gram-negative coverage. It is bactericidal and works best against actively dividing bacteria.

What are the side effects of cefalexin?

The most common side effects are gastrointestinal, including diarrhea, nausea, and abdominal discomfort. Hypersensitivity reactions such as rash and urticaria can occur. Serious but rare adverse effects include anaphylaxis, Clostridioides difficile-associated diarrhea (which can be life-threatening), Stevens-Johnson syndrome, interstitial nephritis, and seizures in patients with renal impairment. Cross-reactivity with penicillins is possible but less common than historically believed, occurring in 1-3% of patients with penicillin allergy.

Can I take cefalexin if I am allergic to penicillin?

It depends on the type and severity of your penicillin allergy. The cross-reactivity between penicillins and cephalosporins is lower than previously thought, around 1-3%. Cefalexin can often be used cautiously in patients with mild or remote penicillin reactions such as childhood rash. However, it should be avoided in patients with recent, severe IgE-mediated reactions like anaphylaxis, angioedema, or Stevens-Johnson syndrome. Always inform your healthcare provider about the specific type of penicillin reaction you experienced.

Is cefalexin effective against MRSA?

No, cefalexin has no activity against methicillin-resistant Staphylococcus aureus (MRSA). As a first-generation cephalosporin, it only covers methicillin-sensitive Staphylococcus aureus (MSSA). In communities or patient populations with high MRSA prevalence, empiric treatment of purulent skin infections should include MRSA-active agents such as trimethoprim-sulfamethoxazole, doxycycline, or clindamycin rather than cefalexin. Culture and susceptibility testing help guide appropriate therapy.

What is the difference between cefalexin and amoxicillin?

Both are beta-lactam antibiotics, but cefalexin is a first-generation cephalosporin while amoxicillin is an aminopenicillin. Cefalexin has better coverage against Staphylococcus aureus (MSSA) due to resistance to staphylococcal penicillinase, making it preferred for skin and soft tissue infections. Amoxicillin has better coverage against Enterococcus and some Gram-negative organisms, making it preferred for otitis media and certain respiratory infections. Amoxicillin is first-line for strep pharyngitis, though cefalexin is an excellent alternative. Cross-allergenicity between the two is low but possible in severe penicillin allergy.

Conditions it is used for

CellulitisImpetigoWound infectionsUrinary tract infectionStreptococcal pharyngitisOtitis mediaOsteomyelitisSeptic arthritis
cefazolincefuroximeceftriaxoneamoxicillinamoxicillin-clavulanateclindamycindicloxacillinpenicillin V

Sources and further reading

DailyMed (FDA labels)StatPearls (NCBI Bookshelf)MedlinePlusWHO ATC/DDD index: J01DB01

Educational content for medical students, prepared by the WhiteCoat Pro editorial team with AI assistance; every page is reviewed by a second AI model for factual errors. It is not medical advice and does not replace the product label, local guidelines or a clinician.