June 2, 2026
Share
Last updated: 2/6/2026
Treatment of stomach ulcer begins by identifying the cause, not by taking an acidity medicine only. An ulcer may occur because of H. pylori, repeated use of some painkillers such as ibuprofen, or other less common factors.
Therefore, when searching for the best treatment for stomach ulcer or the best medicine for treating stomach ulcer, the first question should be: what is the cause of the ulcer? An ulcer caused by H. pylori needs a different treatment from an ulcer caused by painkillers.
Correct treatment of stomach ulcer depends on three main pillars: reducing stomach acid, treating the cause, and following up on ulcer healing. If signs of bleeding, severe pain, vomiting blood, or black stool appear, treating stomach ulcer at home is not enough, and a doctor must be consulted immediately.
Treatment of stomach ulcer is a medical plan that aims to heal the wound in the lining of the stomach or duodenum. Treatment of stomach ulcer often includes medicines that reduce stomach acid, antibiotics when H. pylori is present, and stopping painkillers that irritate the stomach when possible.
Mayo Clinic explains that ulcer treatment may include killing H. pylori, stopping or reducing nonsteroidal anti-inflammatory drugs, and using medicines that help heal the ulcer.
There is no best treatment for stomach ulcer that suits all cases. The doctor chooses the treatment of stomach ulcer according to the cause, severity of symptoms, presence of bleeding, patient’s age, and the medicines the patient uses.
The most important causes of stomach ulcer are H. pylori and regular use of nonsteroidal anti-inflammatory drugs such as ibuprofen.
These two causes are among the main causes of stomach ulcer.
This is important because treatment of stomach ulcer caused by H. pylori differs from treatment of stomach ulcer caused by painkillers.
If the ulcer is caused by H. pylori, the patient usually needs antibiotics with proton pump inhibitors. If it is caused by painkillers, the doctor may recommend stopping them, changing them, or reducing their dose, while using a medicine that protects the stomach.
NIDDK explains that treating the cause helps the ulcer heal and reduces the chance of its recurrence.
Treatment of stomach ulcer with medications depends on the cause of the ulcer and the severity of symptoms. Therefore, the doctor may prescribe one medicine or more, and it is not recommended to use stomach ulcer medications randomly without a clear diagnosis.
Proton pump inhibitors are among the most important stomach ulcer pills. They reduce stomach acid secretion, which helps the stomach lining heal and gradually relieves pain.
Examples include:
These medicines are often used as pills. In some cases of bleeding stomach ulcer, they may be given in hospital through an intravenous route.
If testing confirms the presence of H. pylori, treatment of stomach ulcer usually requires antibiotics with a medicine that reduces stomach acid. In this case, using acidity medicine alone is not enough.
The doctor often prescribes more than one antibiotic, with a proton pump inhibitor, and may add other medicines such as bismuth depending on the case.
It is necessary to complete antibiotic doses as prescribed by the doctor, even if symptoms improve early.
The Saudi Food and Drug Authority confirms that using antibiotics without a prescription or stopping them before the specified duration may contribute to antibiotic resistance and treatment failure.
H2 receptor blockers may be used in some cases to reduce stomach acid secretion and relieve ulcer pain. Examples include famotidine and cimetidine.
They may be suitable for some patients, but the doctor is the one who determines whether they are enough alone or whether stronger treatment is needed.
Antacids may quickly relieve pain and burning, but they are not considered the main treatment of stomach ulcer. They help calm symptoms temporarily, but they do not treat the cause of the ulcer and do not guarantee its healing.
Therefore, they should not be relied on alone if symptoms are persistent or recurrent.
The doctor may prescribe medicines that help protect the lining of the stomach and small intestine, such as sucralfate or misoprostol, especially in some cases that need additional support for ulcer healing.
These medicines are used according to the doctor’s assessment, especially if the ulcer is linked to the use of painkillers or irritation of the stomach lining.
The duration of stomach ulcer treatment differs from one person to another depending on the cause of the ulcer, its severity, and the presence of H. pylori or complications such as bleeding. Therefore, there is no single duration that suits all patients.
In many cases, treatment of stomach ulcer may take from several weeks to about two months. The doctor may need follow-up tests to confirm the success of treatment and healing of the ulcer.
In practical terms:
Disappearance of pain does not always mean that the ulcer has healed completely. Therefore, the duration of stomach ulcer treatment must be followed as determined by the doctor, and the medicine should not be stopped on your own.
Stomach ulcer can be treated successfully in most cases if the cause is treated.
Mayo Clinic explains that treatment of peptic ulcers usually succeeds in healing ulcers. However, if symptoms are severe or persistent despite treatment, the doctor may need to perform an endoscopy to rule out other causes.
Stomach ulcer may return if:
Therefore, permanent treatment of stomach ulcer does not mean simply calming the pain. It means treating the cause and confirming that the ulcer has healed.
The doctor may need stomach ulcer endoscopy when an ulcer is suspected, or when symptoms appear that require a more accurate examination.
Endoscopy helps see the esophagus, stomach, and beginning of the duodenum from the inside, which clarifies the location of the ulcer, its size, and the degree of inflammation of the stomach lining.
You may need gastroscopy in the following cases:
Endoscopy is not used in all cases of stomach ulcer treatment, but it becomes important when symptoms are strong, persistent, or accompanied by warning signs.
Endoscopy is often used to diagnose stomach ulcer, identify its location, and take a sample when needed. However, it may also be a treatment in cases of bleeding.
Mayo Clinic mentions that serious complications such as bleeding or stomach perforation may require treatment by endoscopy or surgery.
Therefore, treatment of stomach ulcer by endoscopy is not for all patients. It is often used when complications are present, especially bleeding, or when direct evaluation inside the stomach is needed.
Immediate medical help must be requested when signs of bleeding or severe pain appear. NHS states the need to go to the emergency department when there is vomiting of red blood or vomit that looks like coffee, blood in the stool, black sticky stool with a very bad smell, or severe abdominal pain.
See a doctor quickly if any of the following appears:
In these cases, treatment of stomach ulcer should not be delayed or replaced with home remedies only.
Home treatment is not a substitute for medical treatment of stomach ulcer. However, it helps reduce stomach irritation and support healing after seeing a doctor.
The following steps may help:
NHS states that the patient can support symptoms by eating smaller meals, avoiding symptom triggers such as fatty or spicy foods, coffee, and chocolate, not smoking, and avoiding excessive alcohol.
There are common mistakes that may make treatment of stomach ulcer slower or less effective. Some of them lead to continued pain, and some increase the risk of ulcer recurrence or complications.
The most notable of these mistakes are:
It is important to understand that improvement of pain does not always mean that the ulcer has healed completely. Therefore, the stomach ulcer treatment plan must be followed until the end, and doses should not be changed or the medicine stopped without consulting the doctor.
The best treatment for stomach ulcer is the treatment that addresses the cause. If H. pylori is present, the patient needs antibiotics with a medicine that reduces acid. If the ulcer is caused by painkillers, the doctor may recommend stopping them or changing them while using proton pump inhibitors.
The duration of stomach ulcer treatment may range from one week to two months depending on the cause and severity of the ulcer. Some patients need medicines for several weeks until the stomach lining heals, and they may need a follow-up test after treatment.
Not every ulcer needs an endoscopy. The doctor may recommend endoscopy when there is bleeding, weight loss, difficulty swallowing, persistent pain, severe symptoms, or no improvement despite treatment. Endoscopy may also be used to follow up on stomach ulcer healing.
Yes, stomach ulcer can be treated in most cases if the cause is treated and the medications are followed. However, ulcer recurrence is possible if H. pylori persists, irritating painkillers are used, or the patient does not follow the treatment plan.
Some acidity medicines are available without a prescription, but they are not always enough to treat stomach ulcer. H. pylori medicines and antibiotics require a prescription and must be used under medical supervision to avoid antibiotic resistance or treatment failure.
Medical Review:
Reviewed by the Magrabi editorial team with the assistance of specialized doctors.
Disclaimer:
This article is for health education purposes only and is not a substitute for consulting a specialist doctor.
Treatment of stomach ulcer depends on the cause, especially H. pylori or the use of anti-inflammatory painkillers, and it is not one medicine for all cases.
Proton pump inhibitors and antibiotics, when needed, often help heal the ulcer. However, vomiting blood, black stool, severe pain, weight loss, or persistence of symptoms requires seeing a doctor immediately.