Esophageal manometry is a diagnostic procedure used to assess the function of the esophagus and the esophageal sphincters by measuring the pressures and patterns of muscle contractions. It is primarily used to diagnose motility disorders such as achalasia, diffuse esophageal spasm, and gastroesophageal reflux disease (GERD).