What causes pain below the right rib cage?
Ribs are curved, slender bones. One end attaches to the vertebrae on either side of the torso, curving outward and forward along the chest wall; the other end is either free-floating or connects to the sternum—the central bone of the chest. Ribs serve vital functions, including protecting critical thoracic organs, maintaining structural stability of the thoracic cavity, and assisting respiration. So, what causes pain beneath the right ribs? The following section addresses this question.

What Causes Pain Beneath the Right Ribs?
1. Costochondritis
In the absence of trauma history, costochondritis is a likely diagnosis. Patients typically experience localized rib pain; after several days, swelling may develop, accompanied by dull or sharp pain. Common causes include viral infection, chronic strain of the costosternal joints, and immune or endocrine abnormalities. Additionally, intercostal neuralgia—characterized by pain beneath the ribs—is another potential cause. It most frequently affects the second or third costochondral junctions with the sternum; if the affected side is the right, pain will manifest beneath the right ribs.

2. Cholecystitis
Since the gallbladder lies beneath the right costal margin, localized gallbladder pain may radiate to the area beneath the right ribs. Most patients with cholecystitis also report a bitter taste in the mouth—a distinguishing feature useful for differential diagnosis. Moreover, the region beneath the right ribs corresponds anatomically to the liver. Hepatic dysfunction—such as hepatitis or cirrhosis—may therefore present as pain beneath the right ribs.

3. Rib Fracture
Trauma to the right ribs may result in fracture, with localized pain at the affected site being the most prominent symptom. Pain intensifies during deep breathing, coughing, or trunk rotation. Patients may also perceive—or even hear—a subtle grating sensation (crepitus) due to bone fragments rubbing against each other. Furthermore, intercostal neuralgia refers to stabbing or burning pain along the distribution of an intercostal nerve, often triggered by viral infection, toxins, or mechanical injury; it is sometimes termed “intercostal neuralgia” or “intercostal neuralgic pain.”
The above outlines the most common causes of pain beneath the right ribs. We hope this information proves helpful.