Pepsin is most active in acidic environments between 37 °C and 42 °C. Accordingly, its primary site of synthesis and activity is in the stomach (pH 1.5 to 2).
The stomach maintains its pH around 4.0. When we drink high pH alkaline water, the water pH comes down; but stomach pH goes up as a result. How high it goes up is a function of the amount and the pH of the alkaline water we drink. When the stomach pH rises above 4.5, the stomach will produce more hydrochloric acid and put it in the stomach to bring the stomach pH down to below 4.0.
How the stomach produces hydrochloric acid is not well known to medical doctors, except pathologists. The chemical formula of hydrochloric acid production is:
H2O + CO2 + NaCl = HCl + NaHCO3