Perhaps you're having difficulty swallowing food or liquid. Or maybe you have the sensation that food is caught in the middle of your chest, and that your chest is burning, and then it becomes a pain that radiates outward, to your arms, back, neck, and jaw. At first thought, this pain may seem like a heart attack. But in fact these are the very symptoms of what is known as an esophageal spasm.

An esophageal spasm is a very irregular—but uncommon—digestive problem. Technically the esophageal spasm is an abnormal contraction of your esophagus muscles. It begins when food and liquid cannot be moved to the stomach and get stuck in the esophagus (according to the National Institutes of Health, very hot or very cold foods may be a trigger), but can be difficult to completely understand. For instance, when experiencing symptoms, it is sometimes hard to tell the difference between an esophageal spasm and an angina (which is a chest discomfort caused by poor blood flow through the blood vessels of the heart muscle).

A certain amount of mystery surrounds the esophageal spasm because its causes are still unknown. However, it can still be identified and treated. The first step is to visit your doctor, where a diagnosis can be made through a series of personal history questions and be confirmed with a number of different tests, which measure A) acid levels in the esophagus, and B) the strength and the pattern of muscle contractions in the esophagus. These test include a barium swallow or endoscopy, both of which use X-rays or a small, lighted viewing instrument to examine the inside of the esophagus.

Additionally, your doctor may perform tests that determine whether your chest pain could be caused by GERD. While there is no known direct link between GERD and esophageal spasms, the latter is often in part treated by attacking symptoms of GERD (such as changing your diet and sleeping habits). Since GERD involves the reflux of food back into the esophagus, it can share symptoms (like the chest pain that radiates to the upper body) with an esophageal spasm.

Whatever your case may be, there are treatments available. According to the National Institutes for Health, in an acute episode, nitroglycerin given under the tongue can be effective. Also, long-acting nitroglycerin and calcium channel blockers are options, and chronic cases are sometimes treated with low-dose antidepressants, such as nortriptyline. Lastly, surgery is an option, but this is only for the most rare, most severe cases.