Antacids are medicines used to treat heartburn and indigestion by reducing the amount of acid in the stomach. They work quickly to relieve symptoms for a few hours, but they do not treat the underlying cause of heartburn and indigestion. Antacids come in two forms: liquid and chewable tablets. They can be purchased over-the-counter without a prescription. There are two types of antacids: those that contain a single active ingredient and those that contain a combination of ingredients. Some common ingredients in antacids include aluminum hydroxide, magnesium carbonate, magnesium trisilicate, magnesium hydroxide, calcium carbonate, and sodium bicarbonate. Antacids are generally considered safe when taken at the recommended dosage for short durations of time by people without contraindications. However, long-term use is not recommended, and people with certain medical conditions, such as liver disease, kidney disease, or heart failure, should avoid certain types of antacids.