What causes a cramp in the upper right abdomen?
Dr. Khan explains that the most common causes of a cramp or pain in the upper right abdomen are gallstones and gallbladder inflammation, trapped gas in the colon near the liver, a strained muscle, liver inflammation such as hepatitis or fatty liver disease, a duodenal ulcer, and kidney stones or infection on the right side.
Less often, pneumonia at the base of the right lung or shingles causes pain in this area.
| Cause | Typical clues |
|---|---|
| Gallstones (biliary colic) | Steady pain after fatty or large meals, may spread to the right shoulder, lasts hours |
| Gallbladder inflammation | Constant pain, fever, tenderness under the right ribs |
| Trapped gas | Crampy, comes and goes, eases after passing gas |
| Liver inflammation | Dull ache, fatigue, dark urine, yellow eyes |
| Duodenal ulcer | Burning pain on an empty stomach or at night |
| Kidney stone or infection | Pain in the side or back, painful urination, fever |
| Muscle strain | Pain with movement or touch after exercise or lifting |
Is upper right abdominal pain my gallbladder?
It often is. Gallbladder pain, called biliary colic, is usually a steady, severe ache under the right ribs or in the upper middle abdomen that starts 30 minutes to a few hours after a fatty or large meal, lasts from about 30 minutes to several hours, and may spread to the right shoulder blade or back with nausea or vomiting.
Pain that lasts longer with fever or yellow skin may mean the gallbladder is inflamed or infected.
Gallbladder pain pattern
- TriggerA fatty or large meal, often in the evening.
- OnsetSteady pain under the right ribs, building over minutes.
- SpreadToward the right shoulder blade or back, with nausea.
- DurationUsually 30 minutes to several hours; longer with fever needs urgent care.
Can the liver cause upper right abdominal pain?
Yes, the liver can cause a dull ache or fullness in the upper right abdomen when it is inflamed or enlarged, as in hepatitis, fatty liver disease or alcohol-related liver disease. Liver problems often cause few symptoms early on, so tiredness, dark urine, pale stools, itching or yellow skin or eyes are important clues. Abnormal liver blood tests and imaging help confirm the cause.
Learn about fatty liver disease symptoms and liver care in Katy and Cypress.
Have symptoms like these?
Dr. Muhammad Ali Khan, a board-certified gastroenterologist and hepatologist, sees adults at our Katy and Cypress offices, serving patients across Greater Houston.
When is upper right abdominal pain an emergency?
Get emergency care for upper right abdominal pain that is severe or lasts more than a few hours, comes with fever or chills, yellow skin or eyes, persistent vomiting, dark urine with pale stools, a rigid belly, or shortness of breath or chest pain. These can signal gallbladder infection, a blocked bile duct, pancreatitis, pneumonia or a heart problem.
Emergency warning signs
- Severe pain lasting more than a few hours
- Fever, chills or persistent vomiting
- Yellow skin or eyes, dark urine or pale stools
- Shortness of breath or chest pain
How can I ease mild upper right abdominal cramps?
For mild cramps that seem to be gas or a muscle strain, try a short walk, a warm compress, gentle stretching and smaller, lower-fat meals. Avoid large fatty meals if gallbladder pain is suspected. If cramps keep returning after meals, see a doctor for an abdominal ultrasound rather than waiting, since gallstone attacks often recur.
Tip: Note your last meal
Write down what you ate and how long before the pain began. A link to fatty meals is one of the strongest clues pointing to the gallbladder.
How is the cause diagnosed?
Diagnosis usually starts with an exam and blood tests, including liver tests, a blood count and lipase, and an abdominal ultrasound to look for gallstones, gallbladder inflammation and liver changes. Depending on the findings, a CT scan, MRI of the bile ducts, a FibroScan for the liver, or an upper endoscopy for ulcers may follow.
Treatment depends on the cause; symptomatic gallstones are often treated with gallbladder removal by a surgeon.
See diet after gallbladder removal and abdominal pain by location.
Get answers instead of guessing
Request a visit with Dr. Muhammad Ali Khan at our Katy and Cypress offices. Call the office to check your insurance coverage; self-pay options are available.
What are the key takeaways?
- Upper right abdominal cramps often come from the gallbladder, liver, trapped gas or a strained muscle.
- Gallbladder pain typically follows fatty meals, lasts hours and may spread to the right shoulder.
- Liver problems may cause a dull ache with fatigue, dark urine or yellow eyes.
- Fever, yellow skin, severe or long-lasting pain needs emergency care.
- An ultrasound and blood tests usually find the cause.
Frequently Asked Questions
What does a gallbladder attack feel like?
A gallbladder attack usually causes steady, intense pain in the upper right or middle abdomen that can spread to the right shoulder or back. It often starts after a fatty meal and can last from thirty minutes to several hours.
Can gas cause pain under the right ribs?
Yes, gas trapped in the bend of the colon near the liver can cause pain under the right ribs. Gas pain usually shifts and eases after passing gas, unlike gallbladder pain.
Can stress cause upper right abdominal pain?
Stress can tighten muscles and worsen digestive symptoms, which may cause discomfort in this area. Ongoing or severe pain should be checked to rule out gallbladder or liver problems.
Do I need a referral to see a gastroenterologist in Katy or Cypress?
Many PPO plans and traditional Medicare do not require a referral, while HMO plans usually do. United Gastroenterology Associates can check your plan before you schedule.
What sources support this article?
- NIDDK — Gallstones
- MedlinePlus — Gallbladder diseases
- MedlinePlus — Liver diseases
- MedlinePlus — Abdominal pain
- MedlinePlus — Hepatitis
Where can you see a gastroenterologist in Katy or Cypress?
United Gastroenterology Associates has two offices: Katy, at 23920 Katy Freeway, Suite 555, next to Memorial Hermann Katy Hospital, and Cypress, at 21216 Northwest Freeway, Suite 640, on US-290. Both are open Monday through Friday, 8:30 AM to 5:00 PM, closed for lunch from 12:00 to 1:30 PM, and serve patients from Fulshear, Richmond and across Greater Houston. Call (346) 340-4414 for either office.
Where is the Katy office?
23920 Katy Freeway, Suite 555
Katy, TX 77494
Memorial Hermann Medical Plaza 1
Where is the Cypress office?
21216 Northwest Freeway, Suite 640
Cypress, TX 77429
On US-290
What should you do next?
If you are dealing with upper right abdomen cramp or any ongoing digestive concern, a focused evaluation can find the cause and start the right treatment. Dr. Muhammad Ali Khan and the team at United Gastroenterology Associates see adults from Katy, Cypress, Fulshear, Richmond, Greater Houston and across Texas. Call (346) 340-4414 or request an appointment today.
If you have severe pain, vomit blood, pass black stools or have chest pain, call 911 or go to the nearest emergency room.



