Endoscopic retrograde cholangiopancreatography (ERCP) is a procedure used to diagnose and treat problems in the bile and pancreatic ducts. Using a flexible tube with a camera, the doctor passes the scope through the mouth, down to the stomach, and into the small intestine. A thin tube is then guided into the ducts, and contrast dye is injected so they can be seen on X-rays. ERCP can remove gallstones, open blockages, place stents, or check for issues like narrowing, inflammation, or tumors—all in a single
procedure.