A gastroscopy is a procedure where a doctor inserts a thin, flexible tube with a camera and light into your mouth and guides it down through your esophagus, stomach, and the first part of your small intestine (the duodenum). The whole thing typically takes 8 to 13 minutes. It’s used both to diagnose problems and, in some cases, to treat them on the spot.
Why Doctors Recommend a Gastroscopy
A gastroscopy is one of the most direct ways to see what’s happening inside your upper digestive tract. Rather than relying on imaging or blood tests alone, your doctor can visually inspect the tissue lining these organs and take small samples if something looks off.
The procedure can identify a wide range of conditions:
- Acid reflux (GERD) and inflammation of the esophagus, stomach lining, or duodenum
- Peptic ulcers in the stomach or duodenum
- Barrett’s esophagus, a condition where the esophageal lining changes in a way that increases cancer risk
- Celiac disease and Crohn’s disease affecting the upper gut
- Hiatal hernia, where part of the stomach pushes up through the diaphragm
- Swallowing disorders
- Cancerous and noncancerous tumors
- Liver cirrhosis and portal hypertension, which can cause swollen veins in the esophagus
In many cases, doctors can also test for H. pylori, a type of bacteria responsible for many peptic ulcers, by taking a tissue sample during the procedure.
What Happens During the Procedure
You’ll lie on your side, and the medical team will give you sedation to keep you comfortable. Most gastroscopies use moderate sedation, which means you’re drowsy and relaxed but not fully unconscious. The most common combination is a sedative paired with a pain-relieving medication. Some facilities use deeper sedation, and in rare cases involving complex procedures or specific patient needs, general anesthesia is used.
Once the sedation takes effect, the doctor passes the endoscope (a tube roughly the width of a finger) through your mouth and down your throat. The camera sends a live image to a monitor, allowing the doctor to examine the lining of your esophagus, stomach, and duodenum in real time. Air is gently pumped in to inflate the space slightly, giving a clearer view. Throughout the procedure, your heart rate, blood pressure, and oxygen levels are monitored.
Biopsies and On-the-Spot Treatment
One of the biggest advantages of gastroscopy is that it’s not just diagnostic. If the doctor sees something that needs a closer look, they can pass tiny instruments through the endoscope to take tissue samples (biopsies). You won’t feel this happening. The samples are sent to a lab for analysis.
Biopsy protocols vary depending on the suspected condition. For celiac disease, four to six samples are typically taken from different parts of the duodenum. For Barrett’s esophagus, samples are taken from four points around the esophagus at regular intervals. If an ulcer looks potentially cancerous, eight or more samples may be collected from its base and edges.
Beyond biopsies, the doctor can also treat certain problems during the same session. An actively bleeding ulcer can be cauterized, meaning the blood vessels are sealed with a heated tool to stop the bleeding. Polyps (small growths on the stomach lining) can be removed if they meet certain criteria. Adenomatous polyps are always removed because they carry a risk of becoming cancerous. Larger fundic gland polyps (over 1 cm) and hyperplastic polyps (over 2.5 cm) are also taken out.
How to Prepare
Your stomach needs to be completely empty for the procedure to be safe and effective. The standard instruction is to stop eating and drinking at midnight the night before. You can take small sips of water up until four hours before your appointment, but in that final four-hour window, nothing should go in your mouth, not even chewing gum. If you eat or drink anything during that time, your procedure will likely be delayed or canceled.
If you take morning medications, swallow them with a few sips of water at least four hours before the procedure. Blood thinners require special attention. If you take warfarin, apixaban, rivaroxaban, or similar medications, your clinic should contact you about two weeks beforehand with instructions on whether to pause or adjust your dose. The same applies to antiplatelet drugs like clopidogrel. If you haven’t heard from your clinic by 14 days before the procedure, call them.
Recovery and What to Expect After
After the gastroscopy, you’ll stay at the clinic or hospital for one to two hours while the sedation wears off. A nurse will check on you before you’re cleared to leave. Because of the sedation, you won’t be able to drive yourself home, so arrange for someone to pick you up.
The most common aftereffect is a sore throat, which is caused by the tube passing through. This typically lasts a day or two and responds well to over-the-counter throat spray. You may also feel mildly bloated from the air introduced during the procedure. Rest for the remainder of that day, and you should be back to your normal activities the following day. If you had any treatment done during the gastroscopy, such as polyp removal or cauterization, your doctor may ask you to stay overnight for observation.
Risks and Complications
Gastroscopy is considered a very safe procedure. Serious complications are rare. Large-scale data on endoscopic procedures show a major bleeding rate of about 0.8 per 1,000 procedures and a perforation rate (a small tear in the lining) of roughly 0.4 per 1,000 procedures. Your risk increases slightly if a therapeutic intervention like polyp removal is performed during the same session, but it still remains low. If a sore throat persists beyond two days, or if you notice signs like severe abdominal pain, fever, or vomiting blood after the procedure, contact your doctor promptly.

