Spirometry is a test that measures lung function by having the patient forcefully exhale air into a mouthpiece. It was originally developed in the 1840s and has since been improved with electronic devices. It is used to diagnose asthma and COPD by measuring airflow obstruction. The test involves withholding some medications beforehand, having the patient blow hard into the device multiple times, and may show a normal pattern or patterns indicating obstruction, restriction, or both. Reversibility testing with a bronchodilator helps distinguish asthma from COPD. Spirometry provides important information about lung health and disease.