Gastric acid
The main constituent of gastric acid is hydrochloric acid which is produced by parietal cells (also called oxyntic cells) in the gastric glands in the stomach. Its secretion is a complex and relatively energetically expensive process. Parietal cells contain an extensive secretory network (called canaliculi) from which the hydrochloric acid is secreted into the lumen of the stomach. The pH of gastric acid is 1.5 to 3.5 in the human stomach lumen, the acidity being maintained by the proton pump H/K ATPase. The parietal cell releases bicarbonate into the bloodstream in the process, which causes a temporary rise of pH in the blood, known as an alkaline tide.
Alkaline mucus
Mucus that serves a protective function against acidic environments generally has a high viscosity, though the thickness and viscosity of the mucus layer can vary due to several factors. For example, alkaline mucus in the stomach increases in thickness when the stomach is distended. The pH level of the mucus also plays a role in its viscosity, as higher pH levels tend to alter the thickness of the mucus, making it less viscous. Because of this, invading agents such as "Helicobacter pylori", a bacterium that causes stomach ulcers, can alter the pH of the mucus to make the mucus pliable enough to move through. Exposure to atmospheric air also tends to increase the pH level of alkaline mucus.