Can an Ulcer Cause Chest Pain?

Peptic ulcers can cause chest pain, and the sensation sometimes mimics a heart attack closely enough to send people to the emergency room. The pain usually originates in the upper abdomen but can radiate upward into the chest, particularly when an ulcer sits high on the stomach or in the duodenum. In rarer and more dangerous scenarios, an ulcer that perforates or erodes through neighboring tissue can produce chest pain so convincing that even experienced clinicians initially suspect a cardiac event.

How an Ulcer Produces Chest Pain

Most peptic ulcers cause a gnawing or burning discomfort in the upper abdomen, somewhere between the navel and the breastbone. But the nerve pathways that carry pain signals from the stomach and duodenum overlap with those serving the lower chest wall. A case report in the Journal of Medical Reports documented a duodenal ulcer that caused persistent pain along the right side of the chest, in dermatome segments that correspond roughly to the mid-back and side rib area. The pain did not respond to the usual cardiac workup because the heart was never the problem. Once ischemic heart disease, pulmonary embolism, aortic dissection, and pneumothorax were ruled out, peptic ulcer disease emerged as the explanation.1PubMed Central. Duodenal ulcer accompanied by intractable right lateral chest pain (T6/T7 dermatomal segments)

This kind of referred pain happens because visceral nerves from the upper digestive tract converge on the same spinal cord segments that receive signals from the chest wall. Your brain can misinterpret where the pain is coming from. The result is chest discomfort that feels very real, very alarming, and very cardiac, even though the source is a crater in your stomach lining or duodenum.

When Perforation Makes Things Dangerous

A peptic ulcer that eats all the way through the stomach or duodenal wall is a surgical emergency, and its first symptom is sometimes chest pain rather than the classic abdominal agony doctors expect. One well-documented case involved a 54-year-old man who arrived at an emergency department with shortness of breath and chest pain. The initial suspicion was a lung or heart problem. Imaging eventually revealed a perforated duodenal ulcer. Free air from the ruptured bowel had collected in the abdominal cavity, pushing up and irritating the diaphragm enough to cause chest pain, respiratory distress, and low oxygen levels.2PubMed Central. Respiratory distress and chest pain: a perforated peptic ulcer with an unusual presentation

The diaphragm is the key middleman here. It separates the chest from the abdomen, and the phrenic nerve that controls it also carries sensory information to the shoulder and lower chest. When a perforated ulcer spills stomach acid and air into the peritoneal cavity, the resulting inflammation can irritate the underside of the diaphragm. That irritation gets interpreted as chest pain or even shoulder-tip pain, steering clinicians away from the abdomen entirely.

The Extreme Case That Can Be Fatal

In very rare instances, an ulcer does not just perforate into the abdominal cavity but erodes through the diaphragm and into the pericardium, the sac that surrounds the heart. A forensic case report described a previously healthy man in his 40s who presented with chest pain and fever. Upper endoscopy found a large gastric ulcer, roughly 7 centimeters, that had eaten through the left side of the diaphragm and formed a direct channel into the pericardial sac. The condition, known as a gastropericardial fistula, was ultimately fatal.3PubMed. A fatal case of gastropericardial fistula due to a benign gastric ulcer

Gastropericardial fistulas are extraordinarily uncommon, but they illustrate an important principle: ulcer-related chest pain is not always innocent referred discomfort. When it is accompanied by fever, rapid deterioration, or signs of shock, the situation can be life-threatening. The forensic authors specifically recommended considering this diagnosis in otherwise healthy adults who develop unexplained chest pain, particularly if they have a known history of gastric ulcers.

Why the Emergency Room Takes All Chest Pain Seriously

Emergency departments treat every case of chest pain as a potential heart attack until the evidence says otherwise. The standard approach is systematic and risk-based: an initial evaluation combines the patient’s history, a focused physical exam, and an electrocardiogram, which together sort people into high, moderate, and low risk categories for a cardiac event.4PubMed. Evaluation of chest pain in the emergency department Only after cardiac causes have been excluded, or at least downgraded in probability, do clinicians begin exploring gastrointestinal explanations.

This means that if you go to an ER with chest pain caused by an ulcer, you will almost certainly undergo cardiac testing first. That process is not a waste of time. A peptic ulcer rarely kills someone in the time it takes to run an ECG and check cardiac enzymes, but a heart attack can. The GI workup comes later, and this is one reason ulcer-related chest pain sometimes goes undiagnosed for weeks or months in people who are repeatedly cleared of heart disease but never sent for a look at their stomach.

The Overlap With GERD, Anxiety, and Depression

Ulcers are not the only gastrointestinal cause of chest pain, and in practice they are not even the most common one. Gastroesophageal reflux disease, or GERD, accounts for a much larger share of non-cardiac chest pain cases. A study that evaluated low-risk chest pain patients found that about 44% had at least moderately severe GERD symptoms. Around a third had depression and roughly 30% had anxiety, and these conditions overlapped heavily: about a third of patients had two or more of these conditions at the same time. The frequency of angina-like chest episodes correlated with both the severity of reflux symptoms and the severity of depressive symptoms.5PubMed Central. Prevalence and Overlap of Noncardiac Conditions in the Evaluation of Low-risk Acute Chest Pain Patients

This overlap matters because it means your chest pain may have more than one contributor. An ulcer might be generating some of the discomfort, acid reflux might be adding to it, and anxiety about the pain itself can amplify everything. Sorting out the relative contribution of each cause usually requires more than one test and sometimes more than one specialist.

What Causes Ulcers That Lead to Chest Pain

The two biggest drivers of peptic ulcer disease are the bacterium Helicobacter pylori and the regular use of non-steroidal anti-inflammatory drugs like ibuprofen, naproxen, and aspirin. H. pylori infection damages the protective mucus lining of the stomach and duodenum, allowing acid to eat into the tissue underneath. A case study examining the link between H. pylori and chest pain concluded that the chest pain associated with H. pylori infection is connected to the peptic ulcers the bacterium causes, rather than being a direct effect of the infection on the heart or lungs.6JOJ Case Studies. Medical Interaction between Helicobacter Pylori and Chest Pain – a Case Study

NSAIDs are the other major culprit. These drugs suppress the production of prostaglandins that normally help protect the stomach lining. With that protection diminished, acid can damage the tissue and create ulcers. The resulting discomfort typically centers on the upper abdomen but can present atypically, including as chest pain.7PubMed Central. Peptic ulcer disease and non-steroidal anti-inflammatory drugs People who take NSAIDs regularly for joint pain or headaches and then develop new chest symptoms should mention the medication use to their doctor, because the connection is not always obvious to the patient or the clinician.

How Doctors Find the Ulcer Behind the Chest Pain

Once cardiac causes are ruled out, an upper endoscopy is the most direct way to look for an ulcer. A study of 100 consecutive patients being evaluated for non-cardiac chest pain found that endoscopy revealed gastric or duodenal ulcers in 6 patients, gastritis or duodenitis in 18 patients, and significant esophagitis in 24 patients. The endoscopy identified a meaningful number of patients with acid-related disease who would not have been diagnosed by other esophageal tests alone.8PubMed. Utility of upper endoscopy in the evaluation of non-cardiac chest pain

That said, endoscopy is not ordered for everyone with non-cardiac chest pain. A Mexican consensus statement on the topic noted that the diagnostic yield of endoscopy in patients with non-cardiac chest pain and no other symptoms is low, and recommended reserving it for patients who have alarm features like unintended weight loss, difficulty swallowing, or vomiting blood, or who have failed to respond to an initial trial of acid-suppressing medication.9Revista de Gastroenterología de México. The Mexican consensus on non-cardiac chest pain In practice, this means many people with mild, intermittent chest pain are started on medication before anyone looks inside their stomach.

The Role of Acid-Suppressing Medication

Proton pump inhibitors, the class of drugs that includes omeprazole and esomeprazole, are often used as both a treatment and a diagnostic test for acid-related chest pain. The logic is straightforward: if your chest pain improves substantially on a PPI, the pain was probably caused by acid. A pooled analysis of trials found that patients with objective evidence of gastroesophageal reflux had a high response rate to PPIs compared to placebo, with a roughly four-fold greater likelihood of significant improvement. Patients without objective evidence of reflux showed essentially no benefit from PPIs.10PubMed. Response of unexplained chest pain to proton pump inhibitor treatment in patients with and without objective evidence of gastro-oesophageal reflux disease

For ulcer-related chest pain specifically, PPIs are the cornerstone of treatment because they reduce acid production and give the ulcer a chance to heal. If H. pylori is found, antibiotics are added. If NSAIDs are the cause, stopping the offending drug is critical. In most cases, once the ulcer heals, the chest pain resolves with it. People who continue to have chest pain after an ulcer has healed on follow-up endoscopy need to consider other contributors, including the GERD and mood-disorder overlap mentioned earlier.

When to Worry and When to Wait

Not all ulcer-related chest pain is an emergency, but some of it is, and the tricky part is that the sensation itself does not reliably distinguish between a harmless episode and a life-threatening one. A few patterns deserve immediate medical attention:

  • Sudden onset: Chest pain that hits abruptly and severely, especially if it follows a period of worsening upper abdominal symptoms, raises concern for perforation.
  • Fever: Chest pain combined with fever can signal that an ulcer has perforated or that infection has spread beyond the GI tract.
  • Shortness of breath: Diaphragmatic irritation from a perforated ulcer can cause respiratory distress that looks like a pulmonary problem.
  • Vomiting blood or black stools: These indicate a bleeding ulcer, which can coexist with the chest-pain presentation and requires urgent care.

If your chest pain is milder, comes and goes with meals, worsens when your stomach is empty, and does not come with any of those alarm features, it is more likely to be uncomplicated ulcer pain that your doctor can evaluate on a non-emergency timeline. But the cardinal rule holds: new chest pain, especially in anyone with risk factors for heart disease, should be evaluated promptly. Let the medical team sort out whether the culprit is your coronary arteries or your duodenum.

Why Ulcer-Related Chest Pain Gets Missed

There are a few reasons this diagnosis slips through the cracks. The first is anchoring bias. When a patient says “chest pain,” clinicians think “heart” by training and by protocol. After cardiac tests come back normal, there is often a sense of relief and a tendency to label the pain as anxiety or musculoskeletal without pursuing a GI workup. The second is that patients themselves may not connect the dots between their stomach and their chest. If the pain feels like it is behind the breastbone, the idea that a stomach ulcer is responsible seems counterintuitive.

The third reason is that the classic ulcer symptom profile does not always show up. Textbooks describe ulcer pain as a burning or gnawing sensation in the epigastric area that improves with food (duodenal ulcers) or worsens with food (gastric ulcers). But some ulcers, especially those on the posterior wall of the stomach or high in the fundus, produce atypical pain patterns that do not match the textbook at all. These are the ones most likely to present as chest pain and most likely to be misdiagnosed.

If you have been through a cardiac workup that came back clean and your chest pain persists, especially if it has any relationship to eating, fasting, or NSAID use, it is worth specifically asking your doctor about the possibility of peptic ulcer disease. The evaluation is straightforward, the treatment is effective, and the relief of finally having an explanation can be almost as good as the relief of the pain going away.

Ulcers and Chest Pain in People Taking Blood Thinners or Aspirin

A population that deserves special mention is the large number of people who take daily low-dose aspirin or other blood thinners for cardiovascular protection. Aspirin is an NSAID and carries the same risk of ulcer formation as its over-the-counter cousins. The irony is sharp: you take aspirin to protect your heart, and it gives you an ulcer that produces chest pain, which sends you back to the cardiologist. This circular trap is surprisingly common in clinical practice, and it can lead to repeated cardiac workups before anyone thinks to scope the stomach.

People on long-term aspirin or dual antiplatelet therapy are sometimes prescribed a PPI alongside their blood thinner specifically to prevent ulcers. If you are in this group and develop new chest pain, make sure your medical team knows about all of your medications, including over-the-counter NSAIDs you might be taking for headaches or joint pain on top of your prescription regimen. The cumulative effect on the stomach lining is greater than any single drug alone.