sofidexFor patientsAre you a clinician? Clinical site

Health Library  ›  Conditions  ›  Ulcers

Condition

Ulcers

Peptic ulcers are open sores in the lining of the stomach or first part of the small intestine.

10 min readConditionReviewed 2026-08-22

PDF
What it is
Open sore in the stomach or upper small intestine lining
Body system
Digestive system
Main symptoms
Upper abdominal pain, nausea, bloating, early fullness
What causes it
H. pylori infection or anti-inflammatory pain medicines
How it is diagnosed
Upper endoscopy; H. pylori breath, stool, or biopsy tests
Main treatment
Acid suppression, infection treatment, and cause removal
Can it be cured?
Sometimes — most heal when causes are treated
Is it an emergency?
Sometimes — bleeding or sudden severe abdominal pain
Long-term outlook
Most heal; recurrence follows persistent or returning causes

Overview

An ulcer is an open sore. This article focuses on peptic ulcers, which form in the lining of the stomach or duodenum. The duodenum is the first part of the small intestine.

An ulcer in the stomach is called a gastric ulcer. One in the duodenum is called a duodenal ulcer. Mouth, skin, pressure, and genital ulcers have different causes and treatments.

The stomach normally protects itself from digestive acid. An ulcer can develop when that protection is weakened or damaged. The two main causes are infection with Helicobacter pylori, usually called H. pylori, and regular use of non-steroidal anti-inflammatory drugs like ibuprofen or naproxen, or NSAIDs. NSAIDs include medicines such as ibuprofen and naproxen.

Most peptic ulcers heal with treatment. They still matter because an untreated ulcer can bleed, block food from leaving the stomach, or make a hole through the digestive tract wall.

Symptoms

Some ulcers cause no symptoms until a complication develops. When symptoms occur, upper abdominal pain or discomfort is common. It may feel burning, aching, or gnawing.

Other possible symptoms include:

Pain may come and go. Food can improve it for some people and worsen it for others. These patterns cannot reliably show whether an ulcer is in the stomach or duodenum.

Indigestion and upper abdominal pain have many possible causes, including acid reflux, medicine side effects, gallbladder problems, and functional dyspepsia. Symptoms alone cannot confirm that you have an ulcer.

Bleeding may cause black, sticky, tar-like stools or vomit containing red blood. Partly digested blood can look like coffee grounds. Slow bleeding may instead cause anaemia, meaning too few healthy red blood cells. This can lead to tiredness, weakness, breathlessness, or pale skin.

Causes and risk factors

H. pylori infection is a major cause. This bacterium can live in the stomach lining and produce long-lasting inflammation. Most infected people do not develop ulcers, but the infection increases the risk.

NSAIDs reduce chemicals that help protect the stomach and duodenal lining. Ulcer risk is higher with larger amounts, longer use, or more than one NSAID. Risk can also be higher in older adults and in people with a previous ulcer or digestive tract bleeding.

Low-dose aspirin can also contribute to ulcers and bleeding. However, aspirin may have been prescribed to prevent a heart attack or stroke. Do not stop prescribed aspirin without medical advice.

Other factors can increase damage or slow healing:

  • Smoking tobacco
  • Combining NSAIDs with certain other medicines that increase bleeding risk
  • Severe physical stress from critical illness, major injury, or extensive burns

Spicy food and everyday emotional stress do not usually cause peptic ulcers. They may make symptoms feel worse for some people. Alcohol is not a leading cause, but heavy use can irritate the stomach and increase bleeding risk.

Rarely, ulcers are linked to conditions that make the stomach produce unusually large amounts of acid, such as Zollinger–Ellison syndrome.

Diagnosis

Your symptoms, medicines, previous ulcers, and family or medical history help guide testing. It is important to mention all pain relievers, including non-prescription products. Some cold and headache medicines contain an NSAID without making this obvious on the front label.

Tests for H. pylori include:

Some medicines can temporarily affect H. pylori test results. A healthcare professional may give instructions about which medicines to pause and when. Do not pause a prescribed medicine without checking first.

An upper endoscopy is the main test used to see and confirm an ulcer. A thin, flexible camera passes through the mouth into the oesophagus, stomach, and duodenum. Sedation is often used. Small tissue samples, called biopsies, can be taken to test for H. pylori or examine an unusual-looking area.

Not everyone with indigestion needs an immediate endoscopy. The decision is influenced by symptoms, age, bleeding risk, medicine use, and local guidance.

A stomach ulcer may sometimes need biopsies or a later endoscopy to confirm healing and exclude another cause. This follow-up is not required for every ulcer.

Treatment and management

Treatment aims to heal the ulcer, remove its cause, relieve symptoms, and prevent bleeding or recurrence.

A proton pump inhibitor, or PPI, is commonly used to reduce stomach acid while the lining heals. Other acid-reducing medicines like omeprazole or lansoprazole may sometimes be used. Symptoms can improve before the ulcer has fully healed, so treatment should be completed as directed.

If H. pylori is present, treatment uses a combination of antibiotics and acid suppression. The exact combination is selected according to factors such as previous antibiotic exposure, allergies, and local antibiotic resistance. Taking the full course matters because incomplete treatment can allow the infection to remain.

A breath or stool test is usually used after treatment to confirm that H. pylori has cleared. The timing matters because antibiotics and acid-suppressing medicines can interfere with the result.

If an NSAID contributed to the ulcer, management may include stopping it, reducing exposure, changing pain treatment, or adding protection for the stomach. This should be planned with a healthcare professional, especially if the medicine or aspirin protects your heart or circulation.

A bleeding ulcer may be treated during endoscopy using clips, heat, or injected treatment. More severe bleeding may require blood transfusion, treatment through a blood vessel, or surgery. A perforation, meaning a hole through the stomach or intestinal wall, usually needs emergency hospital treatment.

Avoid using leftover antibiotics or treating suspected ulcers with acid remedies alone. Acid relief does not remove H. pylori, and symptoms cannot show whether an ulcer is bleeding or fully healed.

Complications

Most ulcers do not cause a serious complication, but possible problems include:

  • Bleeding: This may be sudden and visible or slow enough to cause anaemia
  • Perforation: The ulcer makes a hole through the stomach or duodenal wall
  • Obstruction: Swelling or scarring narrows the outlet of the stomach, causing repeated vomiting or early fullness
  • Penetration: The ulcer extends into a nearby organ

A stomach cancer can sometimes look like an ulcer during endoscopy. This does not mean that a typical ulcer will become cancer. Biopsies and follow-up are used when needed to tell them apart. Long-term H. pylori infection is itself associated with an increased risk of stomach cancer.

Prevention

Not every peptic ulcer can be prevented. There is no vaccine or certain way to avoid H. pylori infection.

Medicine-related risk can sometimes be reduced by using NSAIDs only when needed and as directed. Do not combine NSAIDs unless a healthcare professional has told you to. Check labels because several products may contain the same or similar ingredients.

If you need long-term anti-inflammatory treatment or have had an ulcer before, a healthcare professional can assess whether a different medicine or stomach protection is appropriate.

Not smoking supports healing and reduces recurrence. Limiting alcohol may reduce irritation and bleeding risk. Restrictive “ulcer diets” have not been shown to heal ulcers, so you usually do not need to avoid a food unless it clearly worsens your symptoms.

Living with it and what to expect

Many peptic ulcers heal over weeks after the cause is treated. Pain may settle sooner, but that does not prove the ulcer has healed or that H. pylori has cleared.

An ulcer caused by H. pylori is less likely to return after the infection has been successfully removed. It can recur if treatment does not clear the infection or if infection returns. An NSAID-related ulcer can also come back if the medicine is restarted without a plan to reduce risk.

Some people need repeat testing for H. pylori or another endoscopy. Others need ongoing acid suppression because they must continue a medicine that raises ulcer risk. Follow-up is tailored to the ulcer’s cause, location, appearance, and any complications.

Once an uncomplicated ulcer has healed and its cause has been addressed, most people can return to their usual activities and diet. Persistent pain after treatment may need reassessment because another condition could be responsible.

When to get medical help

Seek emergency help for:

  • Vomiting red blood or material that looks like coffee grounds
  • Black, sticky, tar-like stools, especially with weakness or dizziness
  • Sudden, severe, or steadily worsening abdominal pain
  • Fainting, confusion, clammy skin, or trouble breathing
  • A rigid or very tender abdomen

These can be signs of major bleeding or perforation.

Arrange prompt medical assessment if you have repeated vomiting, trouble swallowing, unexplained weight loss, ongoing loss of appetite, increasing tiredness, or persistent upper abdominal pain. You should also seek advice if symptoms return after ulcer treatment.

Routine follow-up is important after H. pylori treatment, a stomach ulcer, or an ulcer linked to medicine you still need. Keep taking prescribed treatment until you receive instructions to change it.

Go through these one question at a time →

Common questions

Can an ulcer heal on its own?

Symptoms may settle without treatment, but the ulcer or its cause may remain. Untreated H. pylori and continued NSAID exposure can lead to recurrence or complications. Testing and cause-specific treatment make reliable healing more likely.

How do I know if I have a stomach ulcer?

You cannot confirm an ulcer from pain patterns alone. An upper endoscopy can directly identify one. Breath, stool, or biopsy testing can show whether H. pylori is present.

What foods should I avoid with an ulcer?

There is no standard ulcer diet. Spicy, acidic, fatty, or caffeinated items may worsen symptoms for some people but do not cause most ulcers. Avoid only the foods that consistently trouble you, while keeping your diet balanced.

Are ulcers caused by stress?

Normal emotional stress is not a usual direct cause. H. pylori and NSAIDs cause most peptic ulcers. Stress may affect appetite, sleep, smoking, alcohol use, or how strongly pain is felt. Critical illness can cause a separate type of stress-related ulcer in hospital patients.

Is a stomach ulcer cancer?

Most stomach ulcers are not cancer. However, stomach cancer can sometimes resemble an ulcer, which is why a stomach ulcer may be biopsied or checked again after treatment. A duodenal ulcer is very rarely cancerous.

Can I take ibuprofen if I have had an ulcer?

Ibuprofen is an NSAID and can raise the risk of another ulcer or bleeding. Do not restart it without discussing your history and other medicines with a healthcare professional. A different pain treatment or stomach protection may be considered.

Sources

  1. 1National Institute of Diabetes and Digestive and Kidney Diseases. Peptic Ulcers (Stomach or Duodenal Ulcers)
  2. 2National Institute of Diabetes and Digestive and Kidney Diseases. Diagnosis of Peptic Ulcers
  3. 3National Institute of Diabetes and Digestive and Kidney Diseases. Treatment for Peptic Ulcers
  4. 4Chey WD, Howden CW, Moss SF, et al. ACG Clinical Guideline: Treatment of Helicobacter pylori Infection. American Journal of Gastroenterology. 2024;119(9):1730–1753
  5. 5Laine L, Barkun AN, Saltzman JR, Martel M, Leontiadis GI. ACG Clinical Guideline: Upper Gastrointestinal and Ulcer Bleeding. American Journal of Gastroenterology. 2021;116(5):899–917
  6. 6National Institute for Health and Care Excellence. Gastro-oesophageal reflux disease and dyspepsia in adults: investigation and management. Clinical guideline CG184

Cite this page

NLM

sofidex [Internet]. Daloreum; c2026. Ulcers; [reviewed 2026 Aug 22; cited 2026 Nov 10]. Available from: https://sofidex.com/patients/conditions/ulcers

APA 7th

sofidex. (2026, August 22). Ulcers. Daloreum. Retrieved November 10, 2026, from https://sofidex.com/patients/conditions/ulcers

AMA 11th

Ulcers. sofidex. Reviewed August 22, 2026. Accessed November 10, 2026. https://sofidex.com/patients/conditions/ulcers

The cited date is today’s, because a citation records when you read the page. The reviewed date is when a clinician last checked it.