How to Prevent Migraines

If you are prone to migraines, prevention can go a long way in improving your quality of life. In addition to lifestyle modifications, this can include medications, complementary and alternative (CAM) treatments, and, in some cases, even surgical approaches.

Given how debilitating they can be, preventing migraines is the goal of anyone who experiences them. But prevention strategies can be particularly important if your migraines tend to be severe or last for several days, or if your migraine medication produces intolerable side effects or proves ineffective for you.

Tips for Preventing Migraines
 Verywell / Brianna Gilmartin

Home Remedies and Lifestyle

They say that the best offense is a good defense, and that is very true with migraines. Migraines often have several triggers, many of which are tied to lifestyle, and avoiding them can often prevent an episode. The best aspect of this approach: it is side effect-free.

Keep in mind that not every lifestyle factor affects every person the same way. For example, certain foods and sounds can be major migraine triggers for some people, but they might not affect you at all.

Get Enough Sleep

Sleep deprivation is among the most common causes of migraine headaches. Do your best to stick to a sleep schedule that will ensure adequate Zzzzs.

Make adjustments to your sleep environment to address things that may disrupt your sleep (e.g., hang blackout shades to prevent light from creeping in and set your thermostat to a comfortable temperature).

Be Aware of Dietary Triggers

Some people have migraines after eating chocolate, soy products, nitrate-containing foods, monosodium glutamate (MSG), or food coloring.

If you experience migraines after consuming any type of food, write the incident down in a food diary to see if, over time, there is a pattern. If so, avoid the food moving forward.

Steer Clear of Triggering Smells and Sounds

Strong scents like cleaning products, cosmetics, and art materials can trigger a migraine. Try to stay away from prolonged exposure to fumes that provoke your migraines.

If loud noises or certain sounds trigger your migraines, try to keep your environment quiet. Holding a phone to your ear for a long time or wearing headphones can result in a migraine. Consider using a speaker when you have prolonged phone calls. 

Manage Stress

Stress is a common trigger, and related migraines can occur both during and after a stressful situation.

Completely avoiding stressful situations is not realistic, but you can dedicate yourself to employing techniques that can help you better manage it. Exercising, meditating, engaging in a hobby—find what works best for you and carve out time for it every day. Make sure that you also schedule in some down time after particularly stressful events to decompress.

When you are stressed, know that doubling down on your attention to other triggers can also go a long way. For example, make sure you get plenty of sleep when you've hit a hectic patch at work.

Regulate Your Caffeine Intake

Caffeine is a component in some over-the-counter migraine medications such as Excedrin (acetaminophen, salicylic acid, caffeine). That's because caffeine can help control and prevent migraines. But for some people, ingesting caffeine actually induces migraines.

Caffeine is a vasoconstrictor (narrows the blood vessels), and migraine is associated with vasodilation. If your body becomes accustomed to caffeine-induced vasoconstriction, your natural vascular controls will adjust to that. And it can take time (typically a few days) to adapt again when there's a change in your routine.

Typically, it's a change in your caffeine intake that affects migraines. For example, caffeine withdrawal can prompt an episode.

As is the case with most things, listen to your body. If you can tolerate some caffeine, it is best to keep your caffeine intake predictable and regular—both in amount and in timing.

If you notice, however, that caffeine consumption tends to trigger migraines, you might consider simply avoiding it altogether. Be aware that coffee, chocolate, cocoa, and tea all contain caffeine. 

Avoid Bright Lights

Bright lights can trigger a migraine. Consider wearing sunglasses or dimming the lights when possible if you sense that the lights around you are too bright. 

Regulate Your Body Temperature

Migraines have been associated with temperature changes, including exposure to cold and heat. You can try to control your environmental temperature or dress in a way that prevents you from getting too hot or too cold.

If you feel a migraine coming on, or if you know that you have been exposed to one of your migraine triggers, using an ice pack on your neck, shoulders or forehead can reduce your chances of developing a full-blown migraine. Alternatively, using a warm pad might do the trick.


If you have more than three to five migraines per month (or more than five days of migraine headaches per month), your doctor may recommend that you take daily prescription medications for migraine prophylaxis (prevention).

Some of these medications are not formally indicated for migraine prophylaxis, but they are frequently used off-label for this purpose.

Over time, most people experience a fluctuation in the frequency and severity of migraines. You may need to use prescription migraine prophylaxis for years; you may be able to discontinue it after a while when your migraines improve.

Keep in mind that medications used for migraine prophylaxis do not stop or reduce the pain of a migraine headache when you already have one. 

Migraine Doctor Discussion Guide

Get our printable guide for your next doctor's appointment to help you ask the right questions.

Doctor Discussion Guide Man

Anti-CGRP Drugs

Calcitonin gene-related peptide (CGRP) inhibitors are a class of medications used for migraine prevention.

The following are approved by the U.S. Food and Drug Administration (FDA) for migraine prophylaxis:

  • Aimovig (erenumab), a monthly injection
  • Ajovy (fremanezumab), available as a 225 milligram (mg) monthly injection or a 675 mg quarterly (every three months) injection
  • Emgality (galcanezumab), a monthly injection

These medications are antibodies that block the CGRP receptor, which is a pain receptor. CGRP may also cause vasodilation (widening of the arteries) believed to contribute to migraine symptoms. By blocking the action of CGRP, blood vessels may maintain their normal width.


Antidepressants are indicated for the treatment of depression. However, they are often used for migraine prevention as well.

When used for migraine prophylaxis, antidepressants are typically prescribed at a lower dose than recommended for the treatment of depression. These medications, including selective serotonin reuptake inhibitors (SSRIs) and tricyclic antidepressants, interact with neurotransmitters that mediate pain.

It can take up to four to six weeks of daily antidepressant use before you notice a decrease in the frequency and severity of your migraine headaches.


Several medications that are normally used for seizure control can reduce migraine frequency and severity when used on a daily basis.

These include:

Like antidepressants, these medications begin reducing the frequency and severity of migraines after about four to six weeks of daily use. 

Blood Pressure Medications

Daily use of the low-dose antihypertensives Inderal (propranolol) or Lopressor (metoprolol)—categorized as beta-blockers)—or calcium channel blockers Verelan (verapamil) or Nymalize (nimodipine) can be effective in reducing the frequency of migraine headaches for some people.

Since these medications lower blood pressure throughout the body, they are not recommended if you have low or borderline low blood pressure.

Non-Steroidal Anti-Inflammatories

While it is not common, prescription-strength anti-inflammatory medications are sometimes used for migraine prevention, particularly when inflammation is believed to be part of the cause. 


In general, when steroids are used for migraine prevention, they are used for a short period of time (one to two weeks).

In other conditions that cause headaches as a symptom, such as giant cell arteritis, a longer-term prescription for oral steroids may be used (six to 12 months), followed by a gradual reduction in dose.

Oral Contraceptives

Some women experience a decrease in the frequency and severity of migraine headaches when using oral contraceptives. This is more common for women who experience menstrual migraines, but some women with other migraine patterns benefit from using these drugs as well.

In some forms of migraine, mainly with migraine with aura, oral contraceptives are very controversial, given that there may be an increased risk of stroke. It is important to discuss the pros and cons of this treatment with your gynecologist as well as your neurologist.

Some formulations of oral contraceptives can cause migraines for some women, so mention new symptoms to your doctor if you are taking birth control. A change may be necessary.

Surgeries and Specialist-Driven Procedures 

There are several procedures that are used to prevent migraine headaches. These are generally indicated if you have refractory migraines—that is, those that don’t improve with the preventive treatments or those usually used to stop a migraine.

If you experience intolerable side effects from medications, then you may experience better results from a procedure.

Nerve Stimulation

A number of nerve stimulation devices have been approved for migraine prevention. These devices are placed externally in the head to produce vibrations that may help prevent migraines.

Cephaly is a small device that creates superficial nerve stimulation. It is placed on the forehead and turned on daily for 20 minutes to prevent migraines.

GammaCore is a handheld device that's held on the neck to stimulate the vagus nerve. It is used daily to prevent migraines. It was initially approved for migraine treatment and has also subsequently been approved for migraine prevention as well.

Botulinum Toxin Injections

Botulinum toxin injections are used as a preventative strategy for migraine headaches. The effect can last for several months, and treatment often needs to be repeated after a few months. Over time, most people can experience longer periods of improvement, and injections may be scheduled less frequently.

A physician places the injections under the skin and into the muscle in several locations on the head. Botulinum toxin is a muscle paralytic and this action is believed to help prevent migraines for some people.

Migraine Surgery

There are several interventional procedures used for migraine prevention. Migraine surgery includes the injection of pain medications, steroids, or muscle relaxers. The type of procedure your doctor might suggest would be driven by factors such as whether you have an inflammatory component to your migraines and which oral medications have partially helped.

And a more extensive surgical procedure can be used to decompress a nerve or muscle to prevent migraine pain when compression is a factor (such as due to an anatomical problem or trauma). This type of procedure may result in decreased function, which can manifest as loss of sensation or muscle weakness.

Complementary and Alternative Medicine (CAM)

Several alternative therapies have been shown to help with migraine prevention. These strategies tend to be safe, but they may or may not work for you.


There are two ways that magnesium has been used for migraines: acutely at the time of the headache in IV form or orally daily as a preventive.

Magnesium, used orally, at a dose of 400 to 500 mg per day has been shown to reduce the frequency and severity of migraines.

Even though you can get it over-the-counter, do not use magnesium for migraine prevention without your doctor's approval because it can interact with other medications.


Acupuncture may be as impactful as daily meditation use for migraine prevention. Research studies that have reported this benefit of acupuncture generally involved treatments ranging from several times per week to several times per month.

It can be hard to know the number and frequency of acupuncture sessions it might take for you to see benefits, so talk to your doctor and acupuncturist if you are planning to use this approach for migraine prevention.


This is a technique in which people are trained to alter physical responses that are not usually under voluntary control, such as blood pressure and heart rate. Biofeedback training has been found to be a valuable method of migraine prevention, potentially because it reduces stress.

Meditation, Yoga, Tai Chi

These exercises, which are based on physical and cognitive control and awareness, have been found to be effective in reducing the frequency and severity of migraine headaches. This may also be due to reducing stress levels.

A Word From Verywell

Prevention strategies may not seem very important to you if you have a migraine treatment that works. But keep in mind that using migraine medications excessively can induce a rebound effect, meaning your migraines may return after the medication wears off.

Factors such as your migraine triggers, your medical history, and your migraine pattern can help you and your doctor design the best migraine prevention plan for you.

Was this page helpful?
Article Sources
Verywell Health uses only high-quality sources, including peer-reviewed studies, to support the facts within our articles. Read our editorial process to learn more about how we fact-check and keep our content accurate, reliable, and trustworthy.
  1. U.S. National Library of Medicine. Medline Plus. Migraine

  2. Lee MJ, Choi HA, Choi H, Chung CS. Caffeine discontinuation improves acute migraine treatment: a prospective clinic-based studyJ Headache Pain. 2016;17(1):71.doi:10.1186/s10194-016-0662-5

  3. Horváth C. Alterations in brain temperatures as a possible cause of migraine headache. Med Hypotheses. 2014;82(5):529-34.doi:10.1016/j.mehy.2014.02.004

  4. Tanik N, Saçmaci H, Aktürk T. The relationship between exposure to hot/cold weather and the clinical features of headaches in patients with migraine and tension-type headaches. Neurol Res. 2020;42(3):239-243.doi:10.1080/01616412.2020.1723300

  5. U.S. Food & Drug Administration. New Drug Class Employs Novel Mechanism for Migraine Treatment and Prevention

  6. U.S. Department of Health & Human Services. How are migraines treated?

  7. Herd CP, Tomlinson CL, Rick C, et al. Botulinum toxins for the prevention of migraine in adults. Cochrane Database Syst Rev. 2018;6:CD011616. doi:10.1002/14651858.CD011616.pub2.

  8. Jose A, Nagori SA, Roychoudhury A. Surgical Management of Migraine Headache. J Craniofac Surg. 2018;29(2):e106-e108.doi:10.1097/SCS.0000000000004078

  9. Dolati S, Rikhtegar R, Mehdizadeh A, Yousefi M. The Role of Magnesium in Pathophysiology and Migraine Treatment. Biol Trace Elem Res. 2019;November 5.doi:10.1007/s12011-019-01931-z

  10. Da silva AN. Acupuncture for migraine prevention. Headache. 2015;55(3):470-3.doi:10.1111/head.12525

  11. Stubberud A, Varkey E, Mccrory DC, Pedersen SA, Linde M. Biofeedback as Prophylaxis for Pediatric Migraine: A Meta-analysis. Pediatrics. 2016;138(2).doi:10.1542/peds.2016-0675

  12. Vasudha MS, Manjunath NK, Nagendra HR. Changes in MIDAS, Perceived stress, frontalis muscle activity and non-steroidal anti-inflammatory drugs usage in patients with migraine headache without aura following ayurveda and yoga compared to controls: An open labeled non-randomized study. Ann Neurosci. 2018;25(4):250-260.doi:10.1159/000492269