Some migraines can be treated with over-the-counter medications such as ibuprofen, acetaminophen or aspirin, if taken at the first signs of a migraine occurring. When these aren't effective, the most commonly prescribed treatment is a class of drugs called triptans, which are considered more effective than ubrogepant but have a catch: They work by constricting blood vessels around the brain to stop the pain, so they are not considered safe for use by people at risk of cardiovascular disease and stroke. The newly approved drug, on the other hand, has a different molecular target -- a protein involved in the transmission of pain.