Medications for heartburn, acid reflux, and ulcers — protein pump inhibitors (PPIs) — are available both over-the-counter and by prescription. PPIs act by inhibiting the production of stomach acid. Some common brands are: omeprazole (Prilosec), esomeprazole (Nexium), lansoprazole (Prevacid), rabeprazole (AcipHex), pantoprazole (Protonix), dexlansoprazole (Dexilant) and omeprazole with sodium bicarbonate (Zegerid).

PPIs can be very helpful, but used long-term they can damage the kidneys, according to a recent study.

The longer the PPI use, the worse the effects on the kidneys. PPI users had a 28% increased risk of developing chronic kidney disease and a 96% risk of developing kidney failure compared to H2 blocker users.

That's because in addition to their effectiveness at decreasing pain and inflammation, PPIs can upset the balance of other systems and cause both short- and long-term side effects. Their use has been associated with an increased risk of bone fractures , diarrheal illness, growth of benign gastric polyps and certain types of pneumonia. PPIs can also have potentially dangerous interactions with some medications, including heart drugs.

Protein pump inhibitors have also been associated with risk of kidney injury and disease, and this study underscores this risk. Interstitial nephritis is an inflammation of the kidneys that can occur suddenly and resolve, or can become chronic and potentially lead to kidney damageand kidney failure.

Researchers compared PPI use to another class of acid-fighting medications, histamine or H2 blockers, a class that includes: Pepcid (famotidine), Tagamet (cimetidine), Zantac (ranitidine) among others. While effective, many find that these drugs are not as strong as PPIs to treat some gastroesophageal conditions. They are also available both by prescription and over-the-counter.

The researchers followed over 170,000 new PPI users and over 20,000 new histamine blocker users over a five-year period to determine the impact of the two medications on kidney function and health. Neither group had evidence of kidney disease at the start of the study.

The study group was divided by duration of medication use: those who were exposed to the medications for less than 30 days, between 31 and 90 days, from three to six months, from six months to a year and from one to two years.

People in the study who used PPIs had an increased risk of chronic renal disease and of progression of the kidney disease to end stage renal disease. The longer the PPI use, the worse the renal outcome. The group that used the H2 blockers did not show the same increased risk for kidney health. The PPI users had a 28% increased risk of developing chronic kidney disease and a 96% risk of developing kidney failure compared to H2 blocker users.

The study underscores the need for caution in long-term use of PPIs. The researchers recommend PPIs be taken only when medically necessary and for the shortest duration possible for the patient to treat their condition effectively.

If you are taking PPIs do not stop them abruptly without consulting your physician about how to taper or discontinue them. Find out what other medical, dietary and lifestyle changes are available to treat your condition. Finally, avoid self-treating with PPIs without medical advice, even though they are widely available over-the-counter.

The study is published in the Journal of the American Society of Nephrology.