ERCP (Endoscopic Retrograde Cholangiopancreatography)

ERCP stands for Endoscopic Retrograde Cholangiopancreatography. It's a procedure where a thin tube with a camera is passed down your throat and into your stomach. Then, dye is injected into the bile and pancreatic ducts to take X-ray pictures. It can also help fix blockages.

Procedure

What people who've had ERCP (Endoscopic Retrograde Cholangiopancreatography) report

Every report comes from a Lived member, sent anonymously.

Have you had ERCP (Endoscopic Retrograde Cholangiopancreatography) for Bile Duct Stones?

NameHow it went

About ERCP (Endoscopic Retrograde Cholangiopancreatography)

Who It's For

Endoscopic retrograde cholangiopancreatography (ERCP) is a procedure for finding and treating problems in the bile ducts and pancreatic duct. Bile ducts carry bile, a digestive fluid, from the liver and gallbladder to the duodenum, the first part of the small intestine. The pancreatic duct carries digestive juice from the pancreas to the same spot, where the two ducts usually share an opening. In ERCP, a doctor passes a flexible camera tube (an endoscope) through the mouth to that opening, injects contrast dye into the ducts and takes x-rays, then uses small tools to fix what the pictures show. The most common reason for ERCP is a gallstone stuck in the bile duct. It is also used to open ducts that are narrowed, blocked or leaking because of infection, pancreatitis, or tumors of the bile ducts or pancreas, and to take tissue samples. A blocked bile duct often shows up as jaundice (yellowing of the skin and eyes), pain in the upper abdomen, or abnormal liver blood tests. ERCP is now mainly a treatment rather than a test. Because it carries more risk than other ways of looking at these ducts, doctors usually diagnose first with lower-risk imaging: an abdominal ultrasound, an MRCP (magnetic resonance cholangiopancreatography, a magnetic resonance imaging scan of the ducts), or an endoscopic ultrasound. ERCP is chosen when those results, or the overall picture, suggest something that needs treating.

Before the Procedure

You will usually be asked not to eat or drink for several hours beforehand, often up to 8 hours, so the stomach is empty. That lets the doctor see clearly and lowers the chance of stomach contents getting into the lungs. Your team will give the exact cutoff. Go over all your medicines with the care team, including supplements. Blood thinners and anti-platelet medicines matter most, because sphincterotomy (a small cut to widen the duct opening) can bleed; some may need to be paused, and the team decides how based on why you take them. Ask what to do with insulin or other diabetes medicines while fasting. Most other medicines can be taken as usual. Tell the team if you are or might be pregnant, since ERCP uses x-rays and pregnancy can raise the risk of complications; when ERCP is needed in pregnancy, the team adjusts the procedure to protect the fetus. Also mention any past reaction to x-ray contrast dye, and conditions such as sleep apnea or lung or heart disease that affect sedation. Because you will be sedated, arrange for an adult to take you home.

During the Procedure

ERCP is done at a hospital or outpatient center by a gastroenterologist or surgeon with specialized training. An IV line (a small tube in a vein in your hand or arm) is used to give sedation, and some people have general anesthesia with a breathing tube instead. Your throat may be numbed with a spray, and a mouth guard protects your teeth. You lie on an x-ray table, usually on your stomach or left side. Most people are comfortable and remember little of it. The doctor guides the endoscope down the esophagus, through the stomach and into the duodenum, pumping in air so the lining is easier to see. A thin tube is then passed through the endoscope into the ducts, dye is injected, and x-rays show stones, narrowings or leaks. Depending on what is found, the doctor may widen the duct opening with a small cut (sphincterotomy), pull out or crush stones, stretch a narrowed section, place a stent (a small plastic or metal tube that holds a duct open so it drains), or take a biopsy. Many centers give an anti-inflammatory medicine such as indomethacin or diclofenac as a rectal suppository just before or during ERCP, because guidelines recommend it to lower the risk of pancreatitis. In people at higher risk, a temporary small stent may be placed in the pancreatic duct for the same reason. A simple ERCP can be quick; a complex one can take a few hours.

Recovery & Aftercare

You are watched in recovery while the sedation wears off, often for 2 to 6 hours, and some people stay overnight. Bloating and gas from the air used during the procedure, mild nausea and a sore throat are common and usually settle within a day or two. Rest for the remainder of the day, and do not drive until the next day. The team will tell you when to eat: often clear liquids for several hours, then light meals, and some people wait a day before solid food. The doctor can usually share what was seen and done once you are awake. Biopsy results take a few days or longer. If a stent was placed, ask whether and when it needs to be removed or replaced, since plastic stents in particular are temporary. Severe or worsening abdominal or chest pain, a belly that becomes swollen, firm and tender, black or bloody stool, vomiting blood or material that looks like coffee grounds, or trouble breathing needs emergency care right away. Contact the team that did the procedure promptly for fever or chills, repeated vomiting, or trouble swallowing or throat pain that is getting worse.

Risks & Complications

ERCP is generally safe, but it carries more risk than routine endoscopy such as a colonoscopy, which is why doctors try to use it only when treatment is likely to be needed. Complications occur in roughly 5% to 10% of procedures, and people who have one often need hospital care. The most common complication is pancreatitis, inflammation of the pancreas, which happens after about 3% to 7% of these procedures. It causes strong pain in the upper abdomen that often goes through to the back and does not ease with passing gas. Most cases are mild and settle with a short hospital stay, but it can occasionally be severe. Other complications include bleeding, mainly after sphincterotomy, which usually stops on its own or is treated during the procedure; infection of the bile ducts (cholangitis) or gallbladder, more likely when a duct does not drain fully; a tear (perforation) in the duodenum or ducts, which may need further endoscopy or surgery; and reactions to sedation, including breathing or heart problems. Risk depends on the reason for the procedure, how difficult the ducts are to reach, individual health factors and the experience of the team. The preventive steps described above lower the chance of pancreatitis but do not remove it.

Questions to Ask Your Doctor

  1. 1.Do I need ERCP, or could an MRCP or endoscopic ultrasound answer the question with less risk?
  2. 2.What do you expect to do during the procedure, such as removing stones or placing a stent, and what happens if it cannot be completed?
  3. 3.How should I handle my blood thinners or diabetes medicines before the procedure?
  4. 4.What is my personal risk of pancreatitis or other complications, and what will you do to lower it?
  5. 5.If a stent is placed, when does it need to come out or be changed, and who will schedule that?

Last reviewed • Oct 2026

Educational content, not medical advice.