Heartburn occurs when acid from your stomach comes up through the esophagus, the tube connecting the throat to the stomach. Heartburn symptoms can be mild or downright painful; for some people, it only lasts a few minutes, but for others, it can last hours. Everyone gets heartburn sometimes, but if you get it frequently, you may have GERD.