The fastest way to get rid of a migraine is to take medication early, before the pain intensifies, and pair it with rest in a dark, quiet room. Most people can break a mild to moderate attack with over-the-counter pain relievers, while stronger prescription options exist for severe or frequent migraines. What works best depends on your attack severity, how often migraines happen, and how quickly you act.
Over-the-Counter Options That Work
For mild to moderate migraines, a combination of acetaminophen (250 mg), aspirin (250 mg), and caffeine (65 mg) per tablet is one of the most effective OTC choices. The standard dose is two tablets at the onset of symptoms. The caffeine helps your body absorb the pain relievers faster and narrows blood vessels that dilate during an attack. This combination is sold under the brand name Excedrin Migraine, among others.
Ibuprofen and naproxen sodium also work well when taken early. The key with any OTC option is timing. Once a migraine reaches full intensity, these medications become far less effective because your stomach slows down during an attack, delaying absorption. If you notice your usual warning signs (aura, neck stiffness, light sensitivity), take your medication immediately rather than waiting to see if the headache develops.
One important limitation: using OTC pain relievers more than two or three days per week can cause medication-overuse headaches, which ironically make migraines more frequent over time.
Prescription Medications for Stronger Attacks
Triptans are the most widely prescribed class of migraine-specific drugs, and they remain the gold standard for moderate to severe attacks. A large network analysis published in The BMJ compared 17 different medications head to head and found that eletriptan was the most effective, making patients pain-free at two hours at roughly five times the rate of placebo. Rizatriptan and sumatriptan ranked close behind. Triptans work by reversing the blood vessel changes and blocking pain signals specific to migraine.
A newer class of medications called gepants (rimegepant and ubrogepant) offers an alternative for people who can’t tolerate triptans or have cardiovascular risk factors that rule them out. Gepants block a protein called CGRP that plays a central role in migraine pain. They’re effective, though the numbers are more modest: about 1 in 13 patients treated with a gepant becomes pain-free at two hours compared to placebo. The 2023 VA/DoD clinical guidelines give gepants a cautious recommendation for acute treatment, positioning them as a solid second-line choice.
What to Do During an Attack
Medication alone often isn’t enough. These physical strategies can shorten an attack or at least make it bearable while your medication kicks in.
Get into a dark, quiet room. Migraine amplifies your brain’s response to light, sound, and smell. Reducing sensory input isn’t just comfort, it directly lowers the neural activity driving your pain. If you can’t get to a dark room, even closing your eyes with a sleep mask helps.
Apply cold to your head or neck. Cold therapy works by calming a nerve cluster behind the nasal passage that’s involved in migraine pain signaling. A cold pack on the forehead, temples, or back of the neck for 15 to 20 minutes is a simple, well-supported approach. Some people alternate cold on the head with warmth on the neck to relieve muscle tension simultaneously.
Stay hydrated. Dehydration is a common migraine trigger, and once an attack starts, nausea can make it hard to drink. Sipping water or an electrolyte drink steadily, even in small amounts, helps your body process medication and may shorten the attack.
Try caffeine early. If you didn’t take a caffeine-containing pain reliever, a small cup of coffee at the very start of a migraine can help. Caffeine constricts blood vessels and enhances pain relief. But if you’re already hours into an attack or you consume caffeine heavily every day, this is less likely to help.
Preventing Migraines From Coming Back
If you’re getting migraines more than a few times a month, shifting some of your focus from treating attacks to preventing them can dramatically reduce how often they happen.
Three supplements have enough evidence to be worth trying. The American Headache Society recommends magnesium oxide at 400 to 500 mg daily, riboflavin (vitamin B2) at 400 mg daily, and melatonin at 3 mg before bed. These aren’t quick fixes. Most people need six to eight weeks of consistent daily use before noticing a reduction in attack frequency. Magnesium is particularly useful if your migraines come with aura.
Behavioral approaches also have strong numbers behind them. Biofeedback, a technique where you learn to control physical stress responses using real-time monitoring, can reduce migraine frequency and severity by 45% to 60% according to the American Migraine Foundation. Relaxation training produces similar results. These techniques take practice but have no side effects and tend to produce lasting benefits even after formal training ends.
Identifying Your Triggers
Not everyone has obvious dietary triggers, but many people do. The most common food-related triggers include caffeine (both consuming it and withdrawing from it), chocolate, MSG (often hidden on labels as “flavor enhancer”), processed meats, aged cheeses and other dairy, alcohol, artificial sweeteners, and soy products. These foods share chemicals like tyramine and sulfites that can provoke attacks in susceptible people.
A headache elimination diet involves removing all common trigger foods for several weeks, then reintroducing them one at a time to identify which ones affect you personally. This takes patience, but it can reveal triggers you’d never have suspected. Keeping a migraine diary that tracks food, sleep, stress, weather, and hormone changes alongside your attacks makes patterns much easier to spot.
Beyond diet, the most reliable non-food triggers are irregular sleep, skipped meals, dehydration, high stress (or the letdown after stress), and hormonal shifts. You can’t control all of these, but maintaining consistent sleep and meal timing is one of the highest-impact lifestyle changes for reducing migraine frequency.
Wearable Devices for Drug-Free Relief
Several FDA-cleared devices now offer non-drug options for both treating and preventing migraines. Nerivio is a wearable worn on the upper arm that sends mild electrical pulses to activate pain-inhibiting pathways in the brainstem. Cefaly is a forehead-worn device that stimulates the nerve above the eyes most commonly involved in migraine. Both can be used during an attack or daily for prevention.
These devices won’t replace medication for severe attacks, but they’re a useful addition for people who want to reduce how often they take drugs, or who get side effects from triptans. They require a prescription in most cases.
When a Headache Isn’t Just a Migraine
Most migraines, even severe ones, are not dangerous. But certain red flags signal that a headache could be something more serious. Get emergency care if your headache comes on suddenly and reaches maximum intensity within seconds (a “thunderclap” headache), if it’s accompanied by fever with a stiff neck, if you develop weakness or numbness on one side of your body, confusion, difficulty speaking, or changes in vision that don’t resolve.
Other patterns that warrant prompt medical evaluation: a new type of headache starting after age 50, headaches that get progressively worse over days or weeks, headaches triggered by coughing, sneezing, or exertion, and any headache that follows a head injury. A headache that changes dramatically from your usual pattern, even if it doesn’t feel “emergency-level,” is worth getting checked.