Rib Pain When Breathing: Causes and When to Worry

Rib pain that worsens when you breathe most often stems from a musculoskeletal problem, such as a strained intercostal muscle or inflamed cartilage where a rib meets the breastbone. These causes are uncomfortable but generally not dangerous. The concern, though, is that pain in the same area can also come from the lungs, the lining around them, or even organs tucked beneath the lower ribs, and some of those causes require urgent medical attention. Sorting out which category your pain falls into depends on a handful of specific features worth knowing about.

Costochondritis and Tietze’s Syndrome

The single most common reason for sharp rib pain with breathing is inflammation at the joints where the ribs connect to the breastbone. When it involves just pain and tenderness, it is typically called costochondritis. When there is also visible swelling over the joint, the condition is classified as Tietze’s syndrome, a benign, self-limiting condition that most often affects the sternocostal, sternoclavicular, or costochondral joints and tends to involve one side.1PubMed Central. What do we know about Tietze’s syndrome? In either case, the hallmark is tenderness you can reproduce by pressing on the front of the chest. The pain typically gets worse when you take a deep breath, twist your torso, or cough.

Costochondritis can show up after a respiratory infection that involved a lot of coughing, after unusual physical exertion, or sometimes with no obvious trigger at all. It tends to resolve on its own over a few weeks with anti-inflammatory medication and rest, though some cases drag on for months. Despite how alarming the sharp chest pain feels, the condition itself is harmless. A doctor diagnoses it primarily by pressing on the affected joints and ruling out cardiac and pulmonary causes. Imaging and blood work can help confirm the diagnosis, particularly when there is swelling that raises the possibility of Tietze’s syndrome.1PubMed Central. What do we know about Tietze’s syndrome?

Intercostal Muscle Strain

Between each pair of ribs lie layers of intercostal muscles that contract and expand every time you breathe. When one of those muscles is overstretched or partially torn, the result is a sharp or dull pain that spikes with breathing, moving, coughing, or sneezing. This kind of strain usually follows a specific event: lifting something heavy, a hard twist during sports, or even a particularly violent coughing fit during a cold. You can often pinpoint the sore spot by pressing on the side of your rib cage, and the pain tends to be worse on one side only.

Most intercostal strains heal within a few weeks with rest, ice in the first couple of days, and over-the-counter pain relief. The tricky part is that you cannot fully immobilize your rib cage the way you might splint a sprained wrist, because you need those muscles to breathe. Shallow breathing to avoid pain can lead to a secondary problem: mucus pooling in the lungs, which raises the risk of a chest infection. So the general advice is to keep breathing as normally as you can, use pain medication to make that tolerable, and avoid the specific movement that caused the strain until the pain subsides.

Stress Fractures and Rib Fractures

A fractured rib is one of the most painful musculoskeletal causes of breathing-related rib pain, because the broken bone shifts slightly with every breath cycle. Traumatic fractures from a fall, car accident, or contact sport are usually obvious. What surprises many people is that ribs can also develop stress fractures from repetitive motion without any single traumatic event. A case report of a teenage lacrosse player illustrates this well: she developed insidious pain in her upper back and shoulder after a game, with no history of trauma, and the pain eventually worsened to the point of causing difficulty breathing. Imaging confirmed a first-rib stress fracture.2Sports Health. First-rib stress fracture in a high-school lacrosse player: a case report and short clinical review

Stress fractures of the ribs tend to occur in athletes whose sports involve repetitive overhead or twisting motions: rowers, baseball pitchers, and lacrosse players among them. Chronic coughing can also weaken a rib enough for a stress fracture, especially in people with osteoporosis. The treatment is rest and pain management. Unlike long-bone fractures, rib fractures are not typically splinted or casted. Healing takes roughly six weeks, during which deep breathing exercises (painful though they may be) help prevent pneumonia.

Slipping Rib Syndrome

The lower ribs, sometimes called “false ribs,” are not directly attached to the breastbone. Instead, they connect through cartilage to the rib above them. In slipping rib syndrome, that cartilage loosens, allowing one rib to slip underneath the one above it and pinch the intercostal nerve running between them.3PubMed Central. A Comprehensive Review of Slipping Rib Syndrome: Treatment and Management The result is a sharp, catching pain along the lower rib margin that flares with deep breathing, bending, or certain postures. Some people describe a clicking or popping sensation.

Slipping rib syndrome is underdiagnosed partly because it does not show up on standard X-rays or blood tests. Many patients go through repeated visits for “unexplained” rib or abdominal pain before someone performs the “hooking maneuver,” a physical exam test where the doctor curls their fingers under the lower rib margin and pulls forward, reproducing the pop and the pain. Treatment ranges from nerve blocks and physical therapy to surgical stabilization of the rib in stubborn cases. The condition is not dangerous, but the chronic pain can significantly affect quality of life, so getting the right diagnosis matters.

Lung and Pleural Causes

The lungs themselves do not have pain-sensing nerves, but the pleura, the thin two-layered membrane surrounding them, does. When the pleura becomes inflamed (pleurisy), every breath drags the irritated surfaces across each other, producing a sharp, stabbing pain that worsens with inhalation. Pleurisy can accompany viral infections, pneumonia, or autoimmune conditions like lupus. The pain is characteristically “pleuritic”: sharp, localized, worse with breathing in, and often relieved by leaning forward or holding the breath.

Pulmonary embolism, a blood clot lodged in a lung artery, is the most dangerous cause of pleuritic chest pain. A patient may present with chest pain that hurts with breathing, a cough, and progressive shortness of breath, as illustrated in a reported case of a woman who developed these symptoms after a long-haul flight and a recent fall, and was found to have segmental and subsegmental pulmonary emboli on CT imaging.4PubMed Central. Balancing Thrombosis and Bleeding: A Case of Massive Haemothorax Complicating Anticoagulation for Pulmonary Embolism Pneumothorax, a collapsed lung, is another serious possibility. It causes sudden, sharp, one-sided chest pain and breathlessness, often in tall, thin young men or following chest trauma. Both conditions require emergency evaluation.

Pneumonia can also produce rib-area pain with breathing when the infection extends to the pleural surface. This pain is usually accompanied by fever, a productive cough, and general malaise. If you have rib pain with breathing along with fever or colored sputum, a chest infection should be on the list of possibilities your doctor considers.

Pain Referred from Organs Below the Ribs

Not all rib pain originates in the rib cage itself. Organs in the upper abdomen share nerve pathways with the lower ribs and diaphragm, so pain from those organs can be felt as rib or flank discomfort that changes with breathing, simply because the diaphragm moves with each breath and presses on inflamed tissue below it.

Gallbladder disease is a classic example. Biliary pain is typically felt in the upper right abdomen or just below the right rib margin, and it may radiate to the back or right shoulder. It tends to be steady and severe, lasting anywhere from 15 minutes to several hours, and is often accompanied by nausea and vomiting.5PubMed Central. ABC of the upper gastrointestinal tract. Upper abdominal pain: Gall bladder A deep breath can intensify the pain because the diaphragm pushes down on an inflamed gallbladder. In fact, one clinical sign of gallbladder inflammation, Murphy’s sign, involves the patient involuntarily stopping a deep breath when the doctor presses under the right ribs.

Splenic problems, such as an enlarged spleen from a viral infection like mononucleosis, can produce similar referred pain on the left side. Liver inflammation or an abscess may cause right-sided rib pain that worsens with breathing. Kidney infections or stones sitting high in the urinary tract can send pain around the flank into the lower rib area as well. The common thread is that if your rib pain comes with digestive symptoms, urinary changes, or fever, the source might be an organ rather than the rib cage.

Hyperventilation and Anxiety

Breathing-related rib pain does not always have a structural cause. Hyperventilation syndrome, often linked to anxiety or panic, can produce chest and rib pain that feels very real and very physical. The pain pattern in hyperventilation syndrome has been described as sharp, fleeting, and periodic, most often felt along the lower rib margins or the left side of the chest, with the intensity increased by deep breathing, twisting, and bending.6Chest. Hyperventilation Syndrome: A Frequent Cause of Chest Pain

The mechanism involves rapid, shallow breathing that overworks the intercostal muscles and changes blood chemistry enough to cause tingling, light-headedness, and muscle spasm. Because the symptoms so closely mimic musculoskeletal or even cardiac pain, people with hyperventilation syndrome often end up in the emergency department multiple times before the pattern is recognized. This is not a diagnosis you should make on your own. It is a diagnosis of exclusion, meaning a doctor needs to rule out the dangerous causes first. But if you have recurrent episodes of rib pain tied to stress, with tingling in the hands and feet, and all your cardiac and pulmonary workups keep coming back normal, hyperventilation syndrome is worth discussing with your physician.

When a Musculoskeletal Diagnosis Misses Something Serious

One of the unsettling realities of rib pain is that musculoskeletal conditions and serious diseases can coexist, and the musculoskeletal pain can mask the deeper problem. A documented case makes this point vividly: a patient referred to physical therapy for costochondritis improved over four visits across 30 days. On the fifth visit, she reported worsening chest and arm pain along with new symptoms of fatigue, sweating, shortness of breath, and loss of appetite. Even though her pain could still be reproduced with musculoskeletal testing, the physical therapist flagged the change to her physician. A CT scan revealed a non-small cell lung adenocarcinoma.7Physical Therapy. Non-Small Cell Lung Carcinoma: Clinical Reasoning in the Management of a Patient Referred to Physical Therapy for Costochondritis

The lesson is not that every case of costochondritis hides cancer. It is that you should pay attention to changes in your symptoms, especially the addition of new symptoms that do not fit the original pattern. Unexplained weight loss, increasing fatigue, night sweats, a new cough, or worsening shortness of breath layered on top of what seemed like simple rib pain are all reasons to go back to your doctor, even if you already have a diagnosis you are comfortable with.

Red Flags That Warrant Emergency Evaluation

Chest pain in the emergency department can have a wide range of causes, and quick triage is critical because the most dangerous ones, including heart attack, pulmonary embolism, and aortic dissection, need treatment within minutes to hours.8PubMed. Chest pain in the emergency department: Differential diagnosis and diagnostic strategy You should seek emergency care for rib pain with breathing if you also have any of the following:

  • Severe breathlessness: Feeling like you cannot get enough air, especially if it came on suddenly.
  • Rapid heart rate or dizziness: These can point to a pulmonary embolism or significant blood loss.
  • Fever with chills: Suggests infection, which could mean pneumonia, a lung abscess, or a pleural empyema.
  • Pain after trauma: A fall, car accident, or blow to the chest could mean fractured ribs, a punctured lung, or internal bleeding.
  • Coughing up blood: Even a small amount warrants urgent investigation.
  • Recent surgery, immobilization, or long-distance travel: These raise the risk of blood clots. A pulmonary embolism can present as pleuritic chest pain and breathlessness, sometimes developing after long-haul flights or periods of reduced mobility.4PubMed Central. Balancing Thrombosis and Bleeding: A Case of Massive Haemothorax Complicating Anticoagulation for Pulmonary Embolism
  • Crushing or pressure-like pain: Even if it seems to be in the rib area, pressure-type pain radiating to the jaw, arm, or back could indicate a cardiac event.

If none of these apply and the pain is mild, reproducible by pressing on the spot, and not worsening over time, it is reasonable to see your regular doctor within a few days rather than heading to the emergency department. But err on the side of caution: rib pain that is new, severe, or accompanied by any systemic symptom like fever, weight loss, or breathlessness deserves prompt attention.

What Happens at the Doctor’s Office

If your rib pain is not an emergency, a doctor’s first step is a physical exam. They will press on the chest wall to see if the pain can be reproduced, which points toward a musculoskeletal source. They will listen to your lungs for signs of fluid, crackles, or reduced air entry. They will ask about recent illness, injury, travel, and exercise habits.

Depending on what the exam suggests, further steps might include a chest X-ray to look for fractures, pneumonia, or a collapsed lung. Blood work can check for markers of infection or inflammation. If a pulmonary embolism is a concern, a D-dimer blood test and CT angiography may follow. An electrocardiogram is routine for any significant chest pain to rule out cardiac causes. For suspected gallbladder or splenic problems, an abdominal ultrasound is the typical next step. If the pain has been going on for weeks and the initial workup is unremarkable, further imaging such as CT or MRI might be ordered to look for less common causes.

Many people are reassured to learn that their rib pain is musculoskeletal after this workup. For those with slipping rib syndrome or chronic costochondritis that does not respond to basic measures, referral to a pain specialist or thoracic surgeon may be appropriate.

Managing Musculoskeletal Rib Pain at Home

When a doctor has confirmed that your breathing-related rib pain is musculoskeletal, the core of treatment is straightforward. Anti-inflammatory medications like ibuprofen or naproxen reduce both pain and swelling. Applying heat after the first 48 hours can relax tight intercostal muscles. Gentle stretching and gradual return to normal activity prevent deconditioning without re-aggravating the injury.

One mistake people make is bracing or guarding the painful side, taking shallow breaths to avoid discomfort. While understandable, this can lead to a condition called atelectasis, where portions of the lung partially collapse from underuse, and can set the stage for respiratory infections. Controlled deep breathing, even if briefly painful, keeps the lungs expanded and healthy. Taking pain medication about 30 minutes before doing a round of deep-breathing exercises can make this more tolerable. If the pain has not noticeably improved after two to three weeks, or if it worsens, a follow-up appointment is a good idea to reconsider the diagnosis.

Sleeping can be a particular challenge with rib pain. Lying on the unaffected side with a pillow hugged against the painful side for support tends to be the most comfortable position for many people. Sleeping slightly propped up also reduces the pressure on the rib cage. Avoid heavy lifting, vigorous exercise, and sudden twisting until the pain has clearly settled.