When you buy through our links, we may earn a commission. Products or services may be offered by an affiliated entity. Learn more.
Foods That Help You Sleep
At a Glance
Certain foods can help you sleep. These include:
- Melatonin-rich foods: tart cherries like Montmorency cherries, unsweetened tart cherry juice, pistachios, almonds, eggs, and milk
- Foods with tryptophan: turkey, chicken, fish, eggs, cheese, edamame and tofu, peanuts, quinoa, and pumpkin seeds
- Foods high in magnesium: spinach, avocados, bananas, and sweet potatoes
Whether it’s a jolt after a cup of coffee or drowsiness after Thanksgiving dinner, most people have personally experienced how food and drinks can affect their energy and alertness.
Both diet and sleep are complex, which means there’s no silver bullet or single food that’s guaranteed to help with sleep. However, there are some foods and drinks that may make it easier to get a great night’s sleep.
How Specific Foods Can Affect Sleep
Certain foods contain nutrients and compounds that influence sleep-related hormones and brain activity. From regulating melatonin production to stabilizing blood sugar levels overnight, the nutritional components of the food you eat can play a surprising role in how well you rest. Understanding these effects can help you make more sleep-supportive choices at mealtime.
- Melatonin: The hormone melatonin regulates sleep onset and circadian rhythm (i.e., the sleep/wake cycle) .
- Tryptophan: Tryptophan is an amino acid found in certain foods that is metabolized into the sleep-promoting hormone melatonin and serotonin, a neurotransmitter that’s also important for sleep .
- Carbohydrates: Carbohydrates can assist the brain to metabolize tryptophan, which is then converted into serotonin and melatonin .
- Magnesium: Magnesium helps relax the muscles and modulates melatonin in the body .
Melatonin-Rich Foods
A hormone produced by the pineal gland, melatonin plays an important role in regulating sleep and circadian rhythm . Since people tend to make less melatonin with age, consuming foods with melatonin may help increase levels, thus aiding in sleep.
Tart Cherries
As the name indicates, tart cherries have a distinct flavor from sweet cherries. Sometimes called sour cherries, these include cultivars like Richmond, Montmorency, and English morello. They may be sold whole or as a tart cherry juice.
Several studies have found sleep benefits for people who drink tart cherry juice. In one study, people with a diagnosed history of insomnia who drank two one-cup servings of tart cherry juice per day were found to have more total sleep time and higher sleep efficiency.
These benefits may come from the fact that tart cherries have been found to have above-average concentrations of melatonin, which is a hormone that helps regulate circadian rhythm and promote healthy sleep. Tart cherries may also have an antioxidant effect that’s conducive to sleep.
Nuts
Nuts like almonds, walnuts , pistachios, and cashews are often considered to be a good food for sleep. Though the exact amounts can vary, nuts contain melatonin and omega-3’s as well as minerals like magnesium and zinc, which together can help people sleep better.
In a clinical trial using supplements, it was found that a combination of melatonin, magnesium, and zinc helped older adults with insomnia sleep longer and more deeply.
Eggs
In addition to plant-based foods, certain foods derived from animals also contain some melatonin. Eggs are one good example. They contain 1.54 ng/g of melatonin. Some research even suggests they boast more of this sleep-inducing hormone than other animal sources like meat.
Milk
A warm glass of milk at night has long been a natural remedy for a good night’s sleep. It turns out that there’s real science to support milk as a sleep aid.
Milk contains melatonin. However, the time of milking significantly affects the amount. For example, one study found that milk harvested during the night (known as night milk) possessed nearly 10 times more melatonin than daytime milk .
In another study in mice, night milk appeared to have sedative, anxiety-reducing, and sleep-promoting effects. Researchers even noted that night milk had a similar impact to diazepam, a type of medication that produces sedation and relieves anxiety.
Foods That Contain Tryptophan
Tryptophan is an amino acid that’s important for many bodily processes, and it plays a major role in sleep. The body converts tryptophan to melatonin (i.e., the sleep-promoting hormone) as well as serotonin, a neurotransmitter that affects sleep, mood, and pain.
Since it’s an essential amino acid, the body can’t make tryptophan on its own. Meaning, people must rely on food to produce it.
Fatty Fish
A research study found that fatty fish may be a good food for better sleep . The study over a period of months found that people who ate salmon three times per week had better overall sleep as well as improved daytime functioning.
Researchers believe that fatty fish may help sleep by providing a healthy dose of vitamin D and omega-3 fatty acids, which are involved in the body’s release and regulation of serotonin. This study focused particularly on fish consumption during winter and darker months when vitamin D levels tend to be lower.
Turkey
Every 100 grams of turkey contains about a quarter of a gram of tryptophan. However, eating tryptophan-rich turkey alone isn’t likely to make you super sleepy. Pairing it with carbohydrates–-which help tryptophan cross the blood-brain barrier where it can increase serotonin levels—is what triggers the drowsy feeling.
Chicken
Turkey isn’t the only type of poultry rich in tryptophan. This amino acid is also abundant in chicken. One roasted chicken leg contains 697 milligram or 249% of the reference daily intake (RDI). One study even found that the body could better absorb the tryptophan in chicken compared to other food sources .
Cheese
Some research shows a strong link between dairy products like cheese and sleep quality. The sleep-promoting effects are largely related to the high amount of tryptophan in cheese. For instance, cottage cheese, low fat ricotta, and mozzarella are among the top cheeses for tryptophan, containing 59%, 56%, and 56% RDI, respectively.
In addition, dairy cheeses are a good source of serotonin, calcium (which helps the brain convert tryptophan to melatonin), and selenium (which has antioxidant properties that can improve sleep).
Soybeans and Tofu
Soy-based foods, including tofu, are also solid sources of tryptophan. One cup of firm tofu contains 593 milligram of tryptophan, translating to 212% RDI.
In addition to tryptophan, soy beans contain a type of phytoestrogen called isoflavones. It’s thought that these plant-based compounds mimic human estrogen, which helps regulate sleep duration and quality.
Soy beans also contain the non-essential, non-protein amino acid L-ornithine. One study found that L-ornithine could reduce stress and improve sleep quality in people with fatigue .
Foods High in Magnesium
Magnesium can promote sleep in two main ways: It acts as a muscle relaxant by binding to gamma-aminobutyric acid (GABA) receptors (i.e., neurotransmitters known to improve sleep), and it regulates melatonin, affecting sleep-wake cycles.
Bananas
While bananas are best known for their potassium content, they also offer a moderate amount of magnesium. One cup of sliced banana has up to 10% of the daily value (DV) for magnesium.
Bananas also contain carbohydrates, which may impact sleep. Some research suggests that consuming a high quantity of carbohydrates helps the brain metabolize tryptophan, which is then converted into serotonin and melatonin. However, the type of carbohydrate is key. For example, foods that are high in refined carbohydrates and processed sugar are known to disrupt sleep.
Pumpkin Seeds
Though studies are limited, pumpkin seeds may hold promise as a sleep-promoting food thanks to their rich magnesium content. Just a handful (one ounce) of pumpkin seeds provides 37% DV for magnesium. Plus, pumpkin seeds are a significant source of tryptophan as well as other fatty acids, antioxidants, and phytochemicals that support overall health, which is vital for good sleep .
Oats
When it comes to sleep-promoting foods, oats come with a wide range of benefits. For one, they’re great sources of both magnesium and tryptophan. One cup of uncooked oats serves 66% DV of magnesium and 130% RDI for tryptophan.
Whole grains like oats also contain butyric acid, which helps the body make GABA, a neurotransmitter that calms the central nervous system and supports sleep .
Additionally, the complex carbohydrates in oats increase serotonin levels while lowering cortisol, a stress hormone that can impede sleep.
Spinach
Spinach is packed with a number of nutrients that can influence sleep. Firstly, just one cup of boiled spinach contains 37% DV of magnesium and 26% RDI for tryptophan.
Leafy greens like spinach are also rich in other micronutrients that can help sleep including:
- Fiber: linked to deeper, more restorative sleep
- Lutein and zeaxanthin: pigments found in plants that can filter blue light, which is believed to interfere with the body’s ability to produce melatonin
- Lycopene and beta carotene: antioxidants that are associated with better sleep
Other Sleep-Promoting Foods
In addition to well-known options like cherries or milk, a variety of other foods may support better sleep thanks to their calming nutrients or influence on hormone production.
Kiwi
The kiwi or kiwifruit is a small, oval-shaped fruit popularly associated with New Zealand even though it’s grown in numerous countries. There are both green and gold varieties, but green kiwis are produced in greater numbers.
Kiwifruit possesses numerous vitamins and minerals , most notably vitamins C and E as well as potassium and folate.
Some research has found that eating kiwi can improve sleep . In a study, people who ate two kiwis one hour before bedtime found that they fell asleep faster, slept more, and had better sleep quality.
It’s not known for sure why kiwis may help with sleep, but researchers believe that it could relate to their antioxidant properties suppressing inflammatory markers, their ability to address folate deficiencies, and/or a high concentration of serotonin.
Rice
Studies of carbohydrate intake and sleep have had mixed results overall, but some evidence connects rice consumption with improved sleep. A study of adults in Japan found that those who regularly ate rice reported better sleep than those who ate more bread or noodles .
At the same time, sugary beverages and sweets have been tied to worse sleep, so it appears that not all carbohydrates and high glycemic index foods are created equal . Additional research is necessary to fully identify the sleep-related effects of different carbohydrates.
The impact of carbohydrates on sleep may be influenced by what is consumed with them. For example, a combination of a moderate amount of protein that has tryptophan, a sleep-promoting amino acid, and carbohydrates may make it easier for the tryptophan to reach the brain.
Chamomile Tea
A cup of herbal tea before bedtime might be a safe and effective sleep aid. Specifically, studies have found that chamomile tea can significantly improve sleep quality and generalized anxiety . Other research suggests that chamomile can reduce sleep-related problems in menopausal people .
Apigenin, a flavonoid found in chamomile tea, is thought to be the compound that produces the sleepy effect. Apigenin has both anxiolytic and sedative properties, so it can act on the central nervous system, helping to reduce anxiety and promote relaxation.
Foods to Avoid Before Bed
While certain foods can help a person drift off to dreamland, others can have the opposite effect.
- Spicy foods. Not only can spicy foods sabotage shuteye by triggering heartburn, indigestion, and acid reflux, but they can also raise body temperature, which is associated with poorer sleep quality.
- Fatty foods. Saturated fats are linked to less slow-wave, restorative sleep. In fact, consuming foods high in fat is linked to a greater risk of sleep disorders.
- High-sugar foods. People that consume a lot of sugary foods tend to sleep fewer hours, awaken more often through the night, and experience lighter, less restorative sleep.
- Acidic foods: Eating citrus, tomatoes, and other acidic foods before bed can cause an increase in stomach acid and digestive enzymes that can lead to acid reflux, irritation, and discomfort.
- Caffeinated food and drinks: Caffeine is a stimulant that can disrupt sleep. One study found that consuming caffeine even six hours before bedtime still impacted sleep quality .
- Alcohol: While having an alcoholic drink before bed might help someone relax and fall asleep quicker, it can lead to disrupted sleep. This negative effect likely explains why people with alcohol abuse and dependence are more likely to experience chronic sleep issues .
Frequently Asked Questions
Which is better at promoting sleep: food or supplements?
While taking certain supplements like melatonin may help with sleep, a nutrient-dense diet is likely more effective for supporting sleep health. That’s because whole foods have several distinct advantages over supplements:
1. Foods contain a complex combination of vitamins, minerals, and other micronutrients that work together synergistically, offering a wider range of benefits for the body, including better sleep.
2. Foods contain fiber, which is associated with deeper, more restorative sleep.
3. Foods contain phytochemicals and antioxidants, which not only help prevent disease, but may also support sleep.
If you need to take a supplement to fill in nutrient gaps, always consult with a healthcare provider first.
Are there foods people think will help with sleep but do not?
Yes, some foods and drinks are believed to enhance sleep but actually have the opposite effect. Alcohol is a prime example. Its sedative effects cause drowsiness, making it easier to fall asleep. However, alcohol can also shorten the duration of REM (rapid eye movement) sleep and cause a person to wake up more often during the night.
While there’s no single food that’s guaranteed to induce shuteye, the best foods for sleep are whole foods and plant-based foods that contain sleep-promoting nutrients like melatonin, tryptophan, and magnesium.
How late can you have caffeine?
Many people depend on a cup of coffee for a midday energy boost, but caffeine too late in the day can disturb sleep. One study found that consuming caffeine six hours prior to bed significantly disrupted sleep quality.
For most healthy adults, the average half-life of caffeine is five hours
. In other words, it takes about five hours to eliminate approximately half of the caffeine from the body.
Though five hours is the average, many factors can affect how fast a person eliminates caffeine from their system including body weight, certain medical conditions and medications, and an individual’s sensitivity to caffeine.
To ensure caffeine intake doesn’t impact sleep, it’s recommended to limit caffeinated foods and drinks at least six hours before bed or 8 hours if you’re sensitive to caffeine.
Still have questions? Ask our community!
Join our Sleep Care Community — a trusted hub of sleep health professionals, product specialists, and people just like you. Whether you need expert sleep advice for your insomnia or you’re searching for the perfect mattress, we’ve got you covered. Get personalized guidance from the experts who know sleep best.
References
24 Sources
-
Meng, X., Li, Y., Li, S., Zhou, Y., Gan, R. Y., Xu, D. P., & Li, H. B. (2017). Dietary Sources and Bioactivities of Melatonin. Nutrients, 9(4), 367.
https://pubmed.ncbi.nlm.nih.gov/28387721/ -
Shi Y, Han Z, Zhang W, et al. Enhancing melatonin biosynthesis in crops through synthetic genetic circuits: A strategy for nutritional fortification in soybean and stress resistance in cotton. Plant Biotechnology Journal. Published online July 7, 2025.
https://onlinelibrary.wiley.com/doi/10.1111/pbi.70253 -
A.D.A.M. Medical Encyclopedia. (2023, May 12). L-Tryptophan. MedlinePlus.
https://medlineplus.gov/druginfo/natural/326.html -
Benton D, Bloxham A, Gaylor C, Young H. Influence of Carbohydrate on the Stages of Sleep – A Meta-Analysis. Curr Dev Nutr. 2021;5(Suppl 2):896. Published 2021 Jun 7.
https://pmc.ncbi.nlm.nih.gov/articles/PMC8181859/ -
Nisar, M., Mohammad, R. M., Arshad, A., Hashmi, I., Yousuf, S. M., & Baig, S. (2019). Influence of dietary intake on sleeping patterns of medical students. Cureus, 11(2), e4106.
https://pubmed.ncbi.nlm.nih.gov/31058000/ -
dela Peña, I. J. I., Hong, E., de la Peña, J. B., Kim, H. J., Botanas, C. J., Hong, Y. S., Hwang, Y. S., Moon, B. S., & Cheong, J. H. (2015). Milk collected at night induces sedative and anxiolytic-like effects and augments pentobarbital-induced sleeping behavior in mice. Journal of Medicinal Food, 18(11), 1255–1261.
https://pubmed.ncbi.nlm.nih.gov/26501383/ -
Losso, J.N., Finley, J.W., Karki, N., Liu, A.G., Prudente, A., Tipton, R., Yu, Y., & Greenway, F.L. (2018). Pilot study of the tart cherry juice for the treatment of insomnia and investigation of mechanisms. American Journal of Therapeutics, 25(2), e194–e201.
https://pubmed.ncbi.nlm.nih.gov/28901958/ -
Reiter, R. J., Manchester, L. C., & Tan, D. X. (2005). Melatonin in walnuts: influence on levels of melatonin and total antioxidant capacity of blood. Nutrition, 21(9), 920–924.
https://linkinghub.elsevier.com/retrieve/pii/S0899900705001632 -
Rondanelli, M., Opizzi, A., Monteferrario, F., Antoniello, N., Manni, R., & Klersy, C. (2011). The effect of melatonin, magnesium, and zinc on primary insomnia in long-term care facility residents in Italy: A double-blind, placebo-controlled clinical trial. Journal of the American Geriatrics Society, 59(1), 82–90.
https://pubmed.ncbi.nlm.nih.gov/21226679/ -
Muñoz-Jurado A, Escribano BM. Presence of melatonin in foods of daily consumption: The benefit of this hormone for health. Food Chem. 2024;458:140172. doi:10.1016/j.foodchem.2024.140172
https://pubmed.ncbi.nlm.nih.gov/38943958/ -
Hansen, A. L., Dahl, L., Olson, G., Thornton, D., Graff, I. E., Frøyland, L., Thayer, J. F., & Pallesen, S. (2014). Fish consumption, sleep, daily functioning, and heart rate variability. Journal of clinical sleep medicine : JCSM : official publication of the American Academy of Sleep Medicine, 10(5), 567–575.
https://pubmed.ncbi.nlm.nih.gov/24812543/ -
Kashyap S, Devi S, Pasanna RM, Preston T, Kurpad AV. True Digestibility of Tryptophan in Plant and Animal Protein. J Nutr. 2024;154(11):3203-3209. doi:10.1016/j.tjnut.2024.09.014
https://pubmed.ncbi.nlm.nih.gov/39307282/ -
Miyake M, Kirisako T, Kokubo T, et al. Randomised controlled trial of the effects of L-ornithine on stress markers and sleep quality in healthy workers. Nutr J. 2014;13:53. Published 2014 Jun 3. doi:10.1186/1475-2891-13-53
https://pubmed.ncbi.nlm.nih.gov/24889392/ -
Batool M, Ranjha MMAN, Roobab U, et al. Nutritional Value, Phytochemical Potential, and Therapeutic Benefits of Pumpkin (Cucurbita sp.). Plants (Basel). 2022;11(11):1394. Published 2022 May 24.
https://pmc.ncbi.nlm.nih.gov/articles/PMC9182978/ -
Zhu W, Huang L, Cheng H, et al. GABA and its receptors’ mechanisms in the treatment of insomnia. Heliyon. 2024;10(23):e40665.
https://www.sciencedirect.com/science/article/pii/S2405844024166960 -
Richardson, D. P., Ansell, J., & Drummond, L. N. (2018). The nutritional and health attributes of kiwifruit: a review. European journal of nutrition, 57(8), 2659–2676.
https://pubmed.ncbi.nlm.nih.gov/29470689/ -
Lin, H. H., Tsai, P. S., Fang, S. C., & Liu, J. F. (2011). Effect of kiwifruit consumption on sleep quality in adults with sleep problems. Asia Pacific Journal Of Clinical Nutrition, 20(2), 169–174.
https://pubmed.ncbi.nlm.nih.gov/21669584/ -
Yoneyama, S., Sakurai, M., Nakamura, K., Morikawa, Y., Miura, K., Nakashima, M., Yoshita, K., Ishizaki, M., Kido, T., Naruse, Y., Nogawa, K., Suwazono, Y., Sasaki, S., & Nakagawa, H. (2014). Associations between rice, noodle, and bread intake and sleep quality in Japanese men and women. PloS one, 9(8), e105198.
https://pubmed.ncbi.nlm.nih.gov/25127476/ -
Katagiri R, Asakura K, Kobayashi S, Suga H, Sasaki S. Low intake of vegetables, high intake of confectionary, and unhealthy eating habits are associated with poor sleep quality among middle-aged female Japanese workers. J Occup Health. 2014;56(5):359-368. doi:10.1539/joh.14-0051-oa
https://pubmed.ncbi.nlm.nih.gov/25168926/ -
Hieu, T.H. et. al (2019) Therapeutic efficacy and safety of chamomile for state anxiety, generalized anxiety disorder, insomnia, and sleep quality: A systematic review and meta-analysis of randomized trials and quasi-randomized trials. Phytother Res . 2019 Jun;33(6):1604-1615. doi: 10.1002/ptr.6349. Epub 2019 Apr 21.
https://pubmed.ncbi.nlm.nih.gov/31006899/ -
Abbasinia, Hanieh & Alizadeh, Zeinab & Vakilian, Katayon & Jafari, Zohreh & poor, Pegah & Ranjbaran, Mehdi. (2016). Effect of Chamomile extract on sleep disorder in menopausal women. The Iranian Journal of Obstetrics, Gynecology and Infertility. 19. 1-7. 10.22038/ijogi.2016.7631.
https://www.researchgate.net/publication/309266429_Effect_of_Chamomile_extract_on_sleep_disorder_in_menopausal_women -
Drake C, Roehrs T, Shambroom J, Roth T. Caffeine effects on sleep taken 0, 3, or 6 hours before going to bed. J Clin Sleep Med. 2013 Nov 15;9(11):1195-200. doi: 10.5664/jcsm.3170. PMID: 24235903; PMCID: PMC3805807.
https://pubmed.ncbi.nlm.nih.gov/24235903/ -
Coltrain, I., Nicholas, C., & Baker, F. (2018). Alcohol and the Sleeping Brain. Handbook of Clinical Neurology, 125, 415–431.
https://www.ncbi.nlm.nih.gov/pmc/articles/PMC5821259/ -
Institute of Medicine (US) Committee on Military Nutrition Research. Caffeine for the Sustainment of Mental Task Performance: Formulations for Military Operations. Washington (DC): National Academies Press (US); 2001. 2, Pharmacology of Caffeine.
https://www.ncbi.nlm.nih.gov/books/NBK223808/