Nexium 40mg Nexium (esomeprazole) is used to treat gastroesophageal reflux disease (GERD), ulcers, certain bacteria in the stomach, and inflammation of the esophagus. It can also be used to prevent ulcers in patients taking medicines called NSAIDs. Esomeprazole is more popular than other proton pump inhibitors.