Antacids are bases, also known as alkalis, that react with acids to produce relatively neutral solutions of water and salt. According to the National Library of Medicine, antacids in the form of tablets and liquids are used to treat acid reflux by neutralizing excess stomach acid.
During digestion, the human stomach produces an acid meant to break down food. According to Wikipedia, acids are corrosive because their positively charged hydrogen ions can easily cause chemical reactions in other substances. The re-combination of elements during chemical reactions is what breaks down the structural integrity of food in the stomach. Unfortunately, it also can corrode the stomach walls, a process which can be countered by antacids. Bases and acids react to produce more neutral chemicals because the negative ions in the bases essentially cancel out the positive ions in the acids. Neutral substances like water are not as reactive and therefore will not corrode the stomach's walls.
Many different brands of antacids are available for purchase without a prescription. Patient.co.uk lists aluminium hydroxide, magnesium carbonate and magnesium trisilicate as some of the commonly used antacid chemical combinations used to treat conditions such as heartburn and acid reflux disorder. The National Library of Medicine advises patients to take antacids an hour after eating so that the antacid medicine is in the stomach while the stomach acid is breaking down the food.