What to Do for Migraines: Relief and Prevention

When a migraine hits, your priority is stopping the pain as fast as possible. The most effective approach combines the right medication, taken early, with simple environmental changes like dimming lights and staying hydrated. Beyond the immediate attack, a longer-term strategy of identifying triggers and considering preventive options can dramatically reduce how often migraines happen in the first place.

What to Do During an Attack

The single most important rule for treating a migraine is to act fast. Pain relievers work best when taken at the first sign of an attack, before the pain has a chance to build. Waiting even an hour can make the same medication significantly less effective.

For over-the-counter options, ibuprofen at 400 to 800 mg is a reliable first choice, taken every six hours as needed (up to 2,400 mg per day). Naproxen sodium at 275 to 550 mg every two to six hours is another strong option, with a maximum of about 1,500 mg per day. Acetaminophen on its own hasn’t shown much benefit for migraines, but the combination of acetaminophen, aspirin, and caffeine (sold as Excedrin Migraine) does work. The caffeine helps your body absorb the other ingredients faster and constricts blood vessels that dilate during an attack.

While the medication kicks in, move to a dark, quiet room. Light and sound amplify migraine pain because your brain becomes hypersensitive to stimulation during an attack. A cold compress on your forehead or the back of your neck can also help by numbing the area and reducing inflammation. Drink water or an electrolyte drink, since dehydration reduces blood and oxygen flow to the brain, which can make a migraine worse.

When OTC Medication Isn’t Enough

If over-the-counter painkillers don’t give you meaningful relief, prescription options exist that target migraines specifically rather than just dulling pain in general. Triptans have been the gold standard for acute migraine treatment for over 30 years. They work by narrowing blood vessels around the brain and blocking pain signals. Several versions are available as pills, nasal sprays, or injections, and your doctor can help match one to the speed and severity of your attacks.

Triptans aren’t safe for everyone, particularly people with heart disease or high blood pressure, because they constrict blood vessels. Newer medications called gepants (rimegepant and ubrogepant) block the pain-signaling protein that plays a central role in migraines without affecting blood vessels at all. Another newer option, lasmiditan, also avoids the blood vessel constriction that makes triptans risky for some people, though it can cause dizziness and drowsiness.

One important caution: using any acute migraine medication more than about 10 to 15 days per month can lead to medication overuse headache, where the treatment itself starts causing more frequent attacks. If you find yourself reaching for painkillers that often, it’s a signal to shift toward prevention.

Identifying Your Triggers

Migraines are rarely random. Most people have identifiable triggers, and knowing yours lets you sidestep attacks before they start. In surveys of migraine sufferers, lack of sleep is the most commonly reported trigger, affecting roughly 79% of people. Skipping meals comes next at about 49%, followed by hormonal changes related to menstruation at around 47%. Alcohol and smoking are triggers for a smaller percentage.

Other well-established triggers include weather changes (especially barometric pressure drops), strong smells like perfume or cleaning products, bright or flickering lights, and emotional stress. A headache diary, kept for two to three months, is the most practical way to spot your personal patterns. Record what you ate, how you slept, your stress level, the weather, and for women, where you are in your menstrual cycle. After a few weeks, the connections usually become obvious.

Supplements That Reduce Migraine Frequency

Three supplements have enough clinical evidence behind them that the American Headache Society specifically recommends them for migraine prevention. Magnesium oxide at 400 to 500 mg daily is the most widely studied. Many migraine sufferers have lower magnesium levels than average, and supplementing can reduce attack frequency. Riboflavin (vitamin B2) at 400 mg daily has also been shown to decrease how often migraines occur, though it typically takes two to three months of consistent use before the effect becomes noticeable. CoQ10 at 300 mg daily rounds out the list, with research showing it reduces migraine frequency in adults.

These supplements are generally well tolerated and inexpensive, making them a reasonable starting point before moving to prescription preventives. They work best as part of a broader strategy that includes trigger management and consistent sleep and meal schedules.

When to Consider Preventive Medication

Preventive therapy becomes worth pursuing if you experience four or more migraine attacks per month, or at least eight headache days per month. It’s also appropriate if your attacks are severely disabling despite taking the right acute medication, if you can’t tolerate acute treatments, or if you’ve developed medication overuse headache.

Preventive medications are taken daily (or monthly, for some newer options) regardless of whether you have a headache. Several classes of drugs originally developed for other conditions, including certain blood pressure medications, antidepressants, and anti-seizure drugs, have proven effective at reducing migraine frequency by 50% or more. Newer preventive treatments that block the same pain-signaling protein targeted by gepants are available as monthly or quarterly injections and tend to have fewer side effects than the older options.

The goal of preventive treatment isn’t to eliminate migraines completely but to cut their frequency and severity enough that acute medications can handle the rest. Most preventives take four to eight weeks to reach full effect, so patience during the adjustment period matters.

Habits That Protect Against Attacks

Your brain dislikes change. Sharp biological shifts, whether in blood sugar, hydration, sleep schedule, or stress level, are among the most potent migraine triggers. The most effective lifestyle strategy is consistency: going to bed and waking up at the same time every day (including weekends), eating meals at regular intervals so blood sugar stays stable, and drinking enough fluids throughout the day. Electrolyte-containing drinks are particularly beneficial since they help maintain the fluid balance your brain depends on.

Regular aerobic exercise, around 30 minutes most days, has been shown to reduce migraine frequency comparably to some preventive medications. The effect builds over weeks, and the exercise itself needs to be moderate. Intense, unfamiliar exertion can actually trigger an attack. Stress management techniques like progressive muscle relaxation and cognitive behavioral therapy also have solid evidence behind them, especially for people whose migraines track closely with periods of high stress or, paradoxically, the letdown period after stress passes.

Red Flags That Need Urgent Attention

Most migraines, while miserable, aren’t dangerous. But certain headache features signal something more serious. Seek emergency care for a headache that comes on suddenly and reaches maximum intensity within seconds (sometimes called a “thunderclap” headache), any headache accompanied by fever, stiff neck, confusion, seizures, or vision loss, a headache after a head injury, or a significant change in the pattern of headaches you’ve had for years. Focal neurological symptoms that don’t fit your usual migraine aura, like weakness on one side of your body or trouble speaking, also warrant immediate evaluation. These red flags don’t necessarily mean something catastrophic is happening, but they require imaging or other testing to rule out causes that need urgent treatment.