The stomachs of most vertebrates operate at an acidic pH of 2 generated by the gastric H+/K+-ATPase located in parietal cells. The acidic pH in stomachs of vertebrates is believed to aid digestion and to protect against environmental pathogens. Little attention has been placed on whether acidic gastric pH regulation is a vertebrate character or a deuterostome ancestral trait. Here, we report alkaline conditions up to pH 10.5 in the larval digestive systems of ambulacraria (echinoderm + hemichordate), the closest relative of the chordate. Microelectrode measurements in combination with specific inhibitors for acid-base transporters and ion pumps demonstrated that the gastric alkalization machinery in sea urchin larvae is mainly based on direct H+ secretion from the stomach lumen and involves a conserved set of ion pumps and transporters. Hemichordate larvae additionally utilized HCO 3- transport pathways to generate even more alkaline digestive conditions. Molecular analyses in combination with acidification experiments supported these findings and identified genes coding for ion pumps energizing gastric alkalization. Given that insect larval guts were also reported to be alkaline, our discovery raises the hypothesis that the bilaterian ancestor utilized alkaline digestive system while the vertebrate lineage has evolved a strategy to strongly acidify their stomachs