SymptomBones, joints & muscles

Rib Pain: Causes and When to Worry

Rib pain is pain in or around the ribs, felt in the chest wall, side or back. Most rib pain comes from the chest wall itself: a strained muscle between the ribs, a bruised or broken rib, or costochondritis, an inflammation where the ribs join the breastbone. These hurt when you press on the spot, twist or breathe deeply. Pain under the ribs can also come from the lungs, heart, gallbladder, liver, spleen or kidneys. Rib pain with breathlessness, chest pressure or coughing blood needs urgent care.

Also called: Chest wall pain, costal pain, intercostal pain, pain under the ribs

At a glance

Most common causes
Muscle strain, bruised or broken rib, costochondritis.
Other causes
Pleurisy, pneumonia, shingles, slipping rib syndrome, organs under the ribs.
Chest wall clue
Tender to press, worse with twisting, coughing or deep breaths.
How long it lasts
Strains 1 to 3 weeks, broken ribs about 6 weeks, costochondritis weeks to months.
Red flags
Breathlessness, chest pressure, coughing blood, fever, after major trauma.

When to get help

Call 911 or go to the ER

  • Chest pain or pressure spreading to the arm, jaw or back, with sweating, nausea or breathlessness (possible heart attack)
  • Sudden sharp pain with breathlessness, especially after surgery, travel or with a swollen calf (possible blood clot in the lung)
  • Rib pain after a major fall or car crash, with breathlessness, coughing blood or several broken ribs
  • Sudden one-sided pain and breathlessness in a tall, thin young person or someone with lung disease (possible collapsed lung)

See a doctor within a day or two

  • Rib pain with fever, cough and colored phlegm (possible pneumonia)
  • A suspected broken rib in an older adult or someone with lung disease
  • Pain under the right ribs with yellow skin or fever
  • Pain under the left ribs after a blow, especially with recent mononucleosis (possible spleen injury)
  • A burning, band-like pain on one side before a rash appears

Book a routine appointment

  • Rib pain without injury lasting more than 2 to 3 weeks
  • Rib pain with unexplained weight loss, night sweats or bone pain elsewhere
  • Recurring clicking or slipping sensation at the lower ribs

Usually safe to manage at home

  • Tender rib area after coughing, lifting, twisting or sports, with no breathlessness or fever

How to tell where rib pain comes from

FeatureChest wall (muscle, bone, cartilage)Lungs and pleuraHeartOrgans under the ribs
Pressing on the spotReproduces the painUsually notNoTender over the organ
BreathingHurts on deep breathSharp pain on breathingUsually unaffectedOften unaffected
MovementWorse with twistingLittle changeNo changeLittle change
Other cluesRecent strain or injuryCough, fever, breathlessnessPressure, sweating, arm or jaw painLinked to meals, jaundice, urine changes

Common causes of rib pain

Muscle strain

The intercostal muscles between the ribs can be strained by coughing, sneezing, twisting, lifting, rowing, golf or tennis. The area is sore to press and hurts with movement and deep breaths. See muscle strain.

Bruised or broken rib

A fall, blow or car crash can bruise or crack a rib. In older adults and people with osteoporosis, a fracture can happen from minor falls or severe coughing. Pain is sharp, worse with breathing, coughing and lying on that side. A rib fracture usually heals in about 6 weeks.

Costochondritis

Costochondritis is inflammation of the cartilage joining the ribs to the breastbone. It causes sharp, aching pain at the front of the chest, usually on the left, that is tender to press. It can last weeks to months but is harmless. Tietze syndrome is similar but with visible swelling.

Slipping rib syndrome

The lower ribs (8 to 10) are loosely attached. If their ligaments are lax, a rib can slip and irritate a nerve, causing a sharp pain under the lower ribs, sometimes with a click or popping sensation. See slipping rib syndrome.

Shingles

Shingles causes burning or tingling pain along a band on one side of the chest, followed a few days later by a blistering rash. Pain can persist after the rash heals (postherpetic neuralgia).

Lung and chest causes

  • Pleurisy: inflammation of the lining around the lungs causes sharp, stabbing pain on breathing in, often after a viral infection.
  • Pneumonia: cough, fever and pain on breathing.
  • Pulmonary embolism: sudden breathlessness and sharp chest pain, an emergency.
  • Collapsed lung (pneumothorax): sudden one-sided pain and breathlessness.
  • Heart problems: heart attack and pericarditis can cause chest pain that is mistaken for rib pain.

Rib pain left side vs right side

Left side: costochondritis (more often left), heart problems, spleen injury or enlargement, stomach problems such as gastritis, pancreatitis, and the left kidney.

Right side: gallstones and gallbladder inflammation (pain under the right ribs after fatty meals, sometimes spreading to the right shoulder blade), liver problems, and the right kidney.

Either side: muscle strain, broken ribs, pleurisy, pneumonia, shingles and slipping rib syndrome.

Less common causes

  • Fibromyalgia: widespread tender points, including around the ribs
  • Osteoporosis-related fractures without significant injury
  • Cancer that has spread to bone or multiple myeloma, causing persistent, worsening pain, often at night
  • Rheumatological conditions such as ankylosing spondylitis, which can stiffen rib joints

How doctors find the cause

A clinician will ask how the pain started, what makes it worse, and about breathlessness, cough, fever and injury. They will press on the ribs and listen to your lungs and heart. Tests depend on suspicion:

  • ECG and blood tests (troponin) to rule out heart problems
  • Chest X-ray for pneumonia, collapsed lung or displaced fractures. Simple rib fractures often do not show on X-ray, and the treatment is the same either way
  • CT scan after major trauma or if a blood clot is suspected
  • Ultrasound for gallbladder and liver problems
  • Blood tests for infection, inflammation, liver function and, if needed, bone or blood cancers

Treatment and home care

For chest wall pain:

  • Rest from activities that worsen the pain, but keep moving gently.
  • Ice for the first 48 hours after an injury, then heat.
  • Pain relief: acetaminophen (paracetamol) or ibuprofen at the label dose. Avoid NSAIDs with kidney disease, stomach ulcers or blood thinners. Topical NSAID gels can help costochondritis.
  • Breathe deeply and cough every hour or so after a rib injury, holding a pillow against your chest. Shallow breathing can lead to pneumonia.
  • Do not strap or wrap your ribs. This restricts breathing and raises the risk of chest infection.
  • Sleep propped up or on the uninjured side.

Medical treatment depends on the cause: stronger pain relief or nerve blocks for multiple rib fractures, antibiotics for pneumonia, antivirals for shingles started early, and physical therapy for persistent chest wall pain.

Frequently asked questions

Why do my ribs hurt when I breathe?

Pain on breathing is common with chest wall problems such as muscle strain, bruised or broken ribs and costochondritis, because the ribs move with each breath. It can also come from pleurisy or pneumonia. Pain with breathlessness, fever or coughing blood needs prompt medical attention.

What causes rib pain without injury?

Common causes without injury are costochondritis, strain from coughing or exercise, pleurisy, shingles and slipping rib syndrome. Pain under the ribs can also come from the gallbladder, liver, stomach, spleen or kidneys. Persistent pain without injury, especially with weight loss, should be checked.

How do I know if my rib is broken?

A broken rib usually follows a fall or blow and causes sharp, localized pain that worsens with breathing, coughing and pressing on the spot. You may hear or feel a crack. Breathlessness, coughing blood or several painful ribs need urgent assessment. Uncomplicated fractures heal in about 6 weeks.

Is pain under the left rib cage serious?

It is usually from a muscle strain, costochondritis or trapped gas. It can be serious if it comes with chest pressure, breathlessness, sweating or pain spreading to the arm or jaw, which may be a heart problem, or after a blow to the left side, which could injure the spleen.

How long does rib pain last?

A strained intercostal muscle usually improves in 1 to 3 weeks. Bruised ribs take 2 to 4 weeks and broken ribs about 6 weeks. Costochondritis can last several weeks to months but eventually settles. Pain from an illness improves as the cause is treated.

Sources

This guide was written from current patient and clinical guidance, including:

  • American Academy of Family Physicians: Chest wall pain and costochondritis
  • MedlinePlus: Broken rib
  • NHS: Rib pain; Costochondritis
  • American Heart Association: Warning signs of a heart attack
  • Mayo Clinic: Pleurisy