Why Do I Wake Up With a Headache?

Teeth grinding can also cause morning headaches. Mouth guards can prevent those, too, she said.

Medication overuse can cause headaches as well. That includes 15 or more days per month of over-the-counter pain drugs such as aspirin, acetaminophen or nonsteroidal anti-inflammatory medications like ibuprofen, or 10 or more days per month of prescription pain drugs like opioids or triptans. “Patients don’t realize that medicines as simple as Advil, Tylenol and Excedrin are really big culprits,” Dr. Mullin said. The best way to prevent these headaches is to cut back on the drugs if possible, taking them fewer than three times a week.

In rare cases, morning headaches are the result of brain lesions, like tumors, that cause pressure inside the skull, Dr. Mullin said. (On average, brain and spinal cord tumors are diagnosed in only about 24 of every 100,000 people in the United States per year.) Lying down heightens this pressure, so these headaches often occur in the middle of the night or the morning. And the pain is typically so intense that it rouses patients from slumber. “A headache that wakes you up from sleep in the morning is something that, for most neurologists, sets off our ‘This is worrisome’ flags,” she said. Often, an M.R.I. is the next step, to see inside the brain.

Migraines are also a common morning headache culprit, said Dr. Merle Diamond, the president and medical director of the Diamond Headache Clinics in the Midwest. In fact, for unknown reasons, she said, 40 percent of migraines start in the early morning. Many factors can set them off, including alcohol, dehydration, lack of sleep, too much or too little caffeine and eating too much or not enough the night before. Other triggers are cured meats, chocolate, aged cheese and artificial sweeteners, as well as stress, hormonal fluctuations, weather changes and bright lights. Even a change in routine can trigger a migraine, Dr. Diamond said, because “a migraine brain likes things to be really regular.”

Migraines are different from other headaches, Dr. Diamond said. They often throb or pulsate, and they can come with nausea or sensitivity to light or sound. They frequently occur on just one side of the head, and they can endure from four hours to several days if untreated, making it hard for people to go about their lives.

To prevent migraines, Dr. Diamond recommended keeping a headache diary — noting triggers and patterns associated with their onset — and then avoiding those triggers. Depending on the frequency and severity of your migraines, a doctor may also recommend prescription drugs that can prevent or treat migraines. Since 2018, the Food and Drug Administration has approved a handful of new migraine drugs, many of which have fewer side effects than older drugs.