What Medications to Take When You Cannot Sleep

When you have trouble falling or staying asleep, it can be upsetting. When it happens often, it's called insomnia. Many people with insomnia turn to sleep aids for help falling asleep.

This article looks at over-the-counter and prescription sleep medicines. It also discusses other sleep aids and alternatives to medicines, and when you should see a doctor.

Tips to Avoid Taking Sleeping Pills
Verywell / Brianna Gilmartin

What is Insomnia?

Insomnia is the most common sleep disorder. It affects nearly everyone at some point.

Insomnia may be short-lived. When it's related to stress or something that can be identified, it's called acute insomnia. An example of acute insomnia is when you have trouble sleeping the night before a big test.

Insomnia can also become long-term. This is called chronic insomnia. Chronic insomnia occurs at least three nights a week and lasts for at least three months. 

There are strategies that can help you get to sleep. Some are more effective than others. Others may lead to additional problems.

Home Remedies for Sleep

If you have insomnia, you probably want a quick fix. There are a lot of popular home remedies for sleep problems. These include food, drink, and over-the-counter pills. Many of these remedies haven't been shown to work. Some can even have adverse effects.

Herbal Teas

Herbal teas are a popular home remedy for insomnia. There is some evidence they can help you sleep.

Certain herbs like valerian and passionflower have been shown to improve sleep quality. This means they may help you sleep more deeply. They may not help you fall asleep faster, though. 

Be careful when choosing herbal tea as a sleep remedy. Avoid anything that contains caffeine.

Other Foods and Beverages

You may have heard that a glass of warm milk or a turkey sandwich could help you sleep. Unfortunately, many of these remedies haven't been proven to work.

Some foods, like warm milk, can be comforting. This may put you in the right mindset for sleep. A few studies have shown that milk or a mixture of milk and honey can help people sleep.

Certain foods, like turkey, contain tryptophan. Your body converts tryptophan to a neurotransmitter called serotonin. Higher levels of serotonin in your brain may make you feel sleepy.

There is some evidence that tryptophan supplements can improve sleep. However, the tryptophan you get from what you eat probably doesn't work as a sleep aid.

Some foods also contain low doses of melatonin. Melatonin is a naturally occurring hormone that helps regulate your circadian rhythm, or your body's natural sleep cycle.

Tart cherries are an example of a food that contains melatonin. Unfortunately, there isn't enough melatonin in food to help you sleep. You would have to eat a lot of these foods to see any effect.

Recap

Home remedies like herbal tea and warm milk may help. Most foods and drink have only limited benefits, though.

What to Avoid

What you eat or drink before bed could contribute to your insomnia. Here are some foods and beverages that you should avoid consuming before bed.

Caffeine

Many drinks and foods contain caffeine. These include:

  • Coffee
  • Some kinds of tea
  • Chocolate
  • Energy drinks

Avoid these foods and drinks just before bed.

Alcohol

Alcohol has long been used as a sleep remedy. For some people, alcohol is a bedtime routine.

Today we know that alcohol is not an effective sleep aid. Alcohol is a depressant. When you drink alcohol, your body produces more adenosine. Adenosine is a chemical that makes you feel sleepy. 

The sleep you get after you drink alcohol, though, is fragmented and disrupted. Alcohol suppresses REM sleep. REM is the dream stage of sleep.

The sleep you get after you drink alcohol is not refreshing. Afterwards, you may have symptoms of sleep deprivation.

Alcohol use may also increase your risk of obstructive sleep apnea. This is when you stop breathing repeatedly during the night. Alcohol contributes to apnea because it can relax the airway muscles.

The use of alcoholic beverages to help with sleep is not recommended.

Eating Just Before Bed

Avoid eating a large meal just before bed. This can cause nighttime heartburn. Spicy food and tomato products may have the same effect.

Eating food of any kind prompts the release of insulin. This can also promote wakefulness. This is why it's a good idea to eat your last meal a few hours before bed.

Recap

The sleep-promoting effects of food and drink are modest. This means they're not likely to have a big impact on your ability to sleep.

The use of caffeine or alcohol will impair your sleep. Heartburn may also keep you awake if you eat the wrong food too close to bedtime.

Over-The-Counter Sleeping Pills

Some people turn to sleeping pills for help falling asleep. Many of these products claim to provide immediate results. Unfortunately, few can deliver on their promises.

Diphenhydramine

Over-the-counter sleeping pills induce sleepiness as a side effect. Medications that contain a "PM" in the brand name often contain the active ingredient diphenhydramine. ZzzQuil is an example of this kind of medication.

Benadryl (diphenhydramine) is an antihistamine. It is used to treat allergies and may cause sleepiness.

Unfortunately, there is little evidence that this drug can help you sleep. The American Academy of Sleep Medicine doesn't recommend it as a treatment for insomnia.

Melatonin

You can buy melatonin over the counter as a supplement. It may be helpful if you have trouble sleeping because your circadian rhythm is off.

It is important to follow the instructions for taking melatonin. It should not be taken right at bedtime. This is because melatonin has a delayed effect. It doesn't start working for several hours.

Recap

Over-the-counter medications containing diphenhydramine probably won't help you sleep. Melatonin may help if your problem is related to your sleep cycle.

Prescription Sleeping Pills

If home remedies and over-the-counter medications haven't helped, see your doctor. Prescription sleeping pills may be an option.

Benzodiazepines are a common type of sleep aid. They enhance the effects of gamma-aminobutyric acid (GABA). GABA is a neurotransmitter that helps your mind and body relax.

Unfortunately, these drugs can also have dangerous side effects. They can be addictive and have the potential for abuse and overdose. They may also cause daytime drowsiness and problems with thinking and memory.

These drugs are not recommended for long-term use. You may also experience rebound insomnia when you stop using them. 

Examples of benzodiazepines include:

  • Eurodin, ProSom (estazolam): This drug has high rates of abuse. People who take this drug are at an increased risk of falls, delirium, and long-term memory problems. There is also an increased risk of overdose and dependency.
  • Halcion (triazolam): This drug has risks similar to estazolam. It may not be the first choice for use as a sleep aid.
  • Restoril (temazepam): This drug has the same risks of falls, delirium, and long-term memory problems as other drugs in this class. It also has a potential for overdose and dependency.

Other types of prescription sleep aids include:

  • Ambien (zolpidem): This widely prescribed drug enhances GABA. It reduces the average amount of time it takes to fall asleep by five to 12 minutes. It also increases the total sleep time by 29 minutes. Though Ambien is not considered a benzodiazepine, it is chemically similar to one. Because your body processes this drug faster than a benzodiazepine, it is less likely to lead to withdrawal when you stop using it. Ambien may have side effects. It may be associated with temporary memory loss. It may also cause sleep-related behaviors like sleep walking.
  • Belsomra (suvorexant): This drug blocks a signal for wakefulness created by a chemical in the brain called orexin. It reduces the average amount of time it takes to fall asleep by eight minutes. It also reduces the average time spent awake in the night by 16 to 28 minutes.
  • Intermezzo (zolpidem): This drug contains the same active ingredient as Ambien. Because your body processes it faster than Ambien, it can be taken in the middle of the night. This may be helpful if you are unable to fall asleep after awakening.
  • Lunesta (eszopiclone): Like Ambien, this drug enhances GABA. It reduces the average time it takes to fall asleep by 14 minutes. It increases total sleep time by 28 to 57 minutes. Lunesta has an unusual side effect. It can cause a metallic or coppery taste in the mouth.
  • Rozerem (ramelteon): This drug enhances the effects of melatonin. It reduces the average amount of time it takes to fall asleep by nine minutes.
  • Silenor (doxepin): This drug is an antidepressant. It may modestly improve sleep.
  • Sonata (zaleplon): This drug reduces the average time it takes to fall asleep by 10 minutes. Unfortunately, it is metabolized quickly and may wear off within four hours. This may make it helpful for nighttime awakenings.
  • Trazodone: This drug is an older antidepressant. It reduces the average amount of time it takes to fall asleep by 10 minutes. It also reduces the average amount of time spent awake in the night by eight minutes. It is widely used in older people. Unfortunately, it has not been well studied for potential side effects.

There are many prescription sleeping pill options. Each has slightly different side effects. This makes them useful for different scenarios.

To find the right medication for your situation, talk to your doctor.

Never take a combination of sleeping pills without medical supervision. Do not take sleeping pills with alcohol. This increases the risk of overdose, breathing suppression, and death.

How to Avoid Sleeping Pills

Sleeping pills are not right for everyone. They can interact with other drugs. If you are pregnant, they may harm your unborn baby.

You may also be concerned about the potential for addiction. Or, you may dislike the side effects.

Fortunately, there are other ways to manage insomnia. You may find it helpful to simply change your sleep habits.

Start by keeping a regular bedtime and wake time. This will help reinforce your natural circadian rhythm.

Avoid naps during the day. Naps can reduce your body’s natural desire for sleep.

It can also help to reduce the time you spend awake in bed. This is called stimulus control. Use your bed only for sex and sleep. If you can't sleep, get out of bed and do something else until you feel sleepy.

Other alternatives for treating insomnia include:

  • Biofeedback, a therapy that uses sensors to measure your body's functions 
  • Aromatherapy, a form of sleep therapy that uses scents
  • Guided imagery, a relaxation technique
  • Progressive muscle relaxation

A psychologist may also be able to help. Therapy can help you learn to manage any stress and negative feelings associated with insomnia.

Recap

There are other things you can do manage your insomnia. Try changing your sleep habits. Relaxation techniques may also be helpful.

When Should You See a Healthcare Provider?

When you have insomnia, it's natural to want an immediate fix. Unfortunately, it may not be that simple.

If your insomnia is caused by temporary stress, you may decide to endure it. For example, you may have trouble sleeping while preparing for a presentation. Once the presentation is over, your insomnia may go away.

Sometimes insomnia becomes long-term or recurring. If your insomnia is disruptive to your life, you may need help from a doctor.

Seek help at once if your insomnia makes you feel depressed or suicidal.

Start by talking to your primary care doctor. If you need more specialized help, you may be referred to a sleep specialist.

Obstructive sleep apnea is a common cause of long term insomnia. When apnea wakes you up, you may have trouble getting back to sleep. This condition requires special treatment.

You may also benefit from sleep therapy. Cognitive behavioral therapy for insomnia (CBTI) is one example. You can learn about this from a book, an online course, a workshop, or class. A psychologist can also help you get started.

Summary

Insomnia affects nearly everyone at some point. Unfortunately, many home remedies can be ineffective. Warm milk and herbal tea may help. Foods and over-the-counter sleep aids tend to be much less effective. Some substances like alcohol can actually disrupt your sleep.

Prescription sleeping pills are another option. Be aware that some can have dangerous side effects. They may also be addictive.

If you would prefer to avoid sleeping pills, changing your sleep habits can help. Therapy may be useful, too. You may also be able to get help from a sleep specialist.

A Word From Verywell

Many people with insomnia can learn to sleep normally without sleeping pills. In some cases, an underlying sleep disorder like sleep apnea may be contributing to your insomnia. These disorders need to be identified.

Even if you've had insomnia for decades, an expert in sleep medicine can help you resolve it. Reach out to get the help you need. Don't hesitate to look beyond the pills and prescription medications that are so often offered first as a way to improve insomnia.

Frequently Asked Questions

  • Are there any proven natural sleep aids?

    Some natural sleep aids may be considered relatively safe for adults in low doses. These include:

    • Melatonin
    • Magnesium
    • Valerian
    • Tryptophan
    • Passionflower
    • Chamomile
    • Gingko biloba
    • CBD
    • Lavender

    Speak to your doctor before trying a natural sleep aid. Always make sure to follow the instructions precisely.

  • How common is insomnia?

    Insomnia is very common. It occurs in 33% to 50% of American adults.

  • What causes insomnia?

    Short-term insomnia and chronic insomnia are caused by a number of things. These can include:

    • Stress
    • Mental health problems
    • Chronic pain
    • Chronic diseases
    • Digestive disorders
    • Hormone fluctuations
    • Medication
    • Neurological conditions
    • Other sleep disorders
  • What happens if chronic insomnia goes untreated?

    Lack of sleep or poor-quality sleep can eventually lead to other problems, including:

    • Weight gain and obesity
    • Diabetes
    • Driving accidents
    • Falls
    • High blood pressure
    • Mood disorders
Was this page helpful?
12 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. Sateia MJ, Buysse DJ, Krystal AD, Neubauer DN, Heald JL. Clinical practice guideline for the pharmacologic treatment of chronic insomnia in adults: An American Academy of Sleep Medicine clinical practice guidelineJ Clin Sleep Med. 2017;13(2):307–349. doi:10.5664/jcsm.6470

  2. Yarnell E. Herbal medicine for insomnia. Altern Complementary Ther. 2015;21(4):173-9. doi:10.1089/act.2015.29011.eya

  3. Fakhr-Movahedi A, Mirmohammadkhani M, Ramezani H. Effect of milk-honey mixture on the sleep quality of coronary patients: a clinical trial study. Clin Nutr ESPEN. 2018;28:132-5. doi:10.1016/j.clnesp.2018.08.015

  4. Sutanto CN, Loh WW, Kim JE. The impact of tryptophan supplementation on sleep quality: a systematic review, meta-analysis, and meta-regression. Nutr Rev. 2021 May 3. doi:10.1093/nutrit/nuab027

  5. Johns Hopkins All Children's Hospital. Does eating turkey make me sleepy

  6. National Sleep Foundation. How alcohol affects the quality—and quantity—of sleep.

  7. National Center for Complementary and Integrative Health. Sleep disorders: in depth.

  8. Johnson B, Streltzer J. Risks associated with long-term benzodiazepine use. Am Fam Physician. 2013;88(4):224-6.

  9. National Sleep Foundation. Sleep hygiene.

  10. National Sleep Foundation. Cognitive behavioral therapy for insomnia.

  11. National Sleep Foundation. Are natural sleep aids safe?

  12. Cleveland Clinic. Insomnia.