Melatonin: What is it and how does it affect sleep?

Hermina Drah
Dr. David Miles
Written by Hermina Drah on 09 April 2024
Medically reviewed by Dr. David Miles on 11 June 2024

Melatonin, a hormone naturally present in the body, regulates sleep patterns, but supplementation of it can also help in treating chronic pain, irregular menstrual cycles, and depression. With age, melatonin levels can drop and light exposure at night blocks the production of melatonin in the brain, leading to irregular sleep patterns.

Melatonin dietary supplements can help increase sleep quality and regulate circadian rhythms. Here is everything you need to know about melatonin, including the safety precautions.

Melatonin: What is it and how does it affect sleep?

What is Melatonin?

Melatonin, a hormone created by the brain's pineal gland (a tiny, pea-sized gland crucial to the human endocrine system) plays a critical part in sleep regulation and other bodily functions. Namely, it helps manage the 24-hour internal clock or the timing of circadian rhythms. When exposed to darkness, melatonin levels naturally rise, facilitating sleep. 

On the flip side, during daylight, melatonin levels decrease to promote wakefulness.

Beyond light exposure during the night, there are a few things that can decrease natural melatonin levels.

  • Advanced age: Melatonin production declines as you age, making it difficult to fall asleep naturally for older individuals.
  • Jet lag and shift work: Travelers and flight crew can experience disruption in natural circadian rhythms, leading to a fall in melatonin production.
  • Alcohol and caffeine consumption: If you drink coffee or alcohol during the evening, you might find falling asleep more challenging. That's because caffeine and alcohol reduce melatonin production and affect dopamine production. 

If you suffer from poor melatonin production or struggle to sleep naturally, melatonin supplements may prove a useful alternative to other sleeping aids such as benzodiazepines or sleeping pills.

How Does Melatonin Work?

Over-the-counter melatonin works by adding to the natural melatonin your brain is already producing. Melatonin supplements are lab-created, and they're usually available as oral capsules or tablets.

Melatonin tablets or capsules don’t directly induce sleep. Instead, it supplements the body’s naturally occurring melatonin which increases in the evening. Supplementation is used to support sleep quality for people dealing with jet lag and irregular sleep schedules due to school, work, or other sleep problems and insomnia.

Melatonin is effective for some conditions such as disruptions of the circadian rhythm in the blind. This is because blind individuals are unable to perceive light, and therefore cannot distinguish night and day. Naturally, this leads to the disruption of melatonin cycles and disturbances in circadian rhythms. 

Natural melatonin supplements can also regulate menstrual cycles. Based on the findings of a study dealing with PMS and PMDD-related symptoms and melatonin, the hormone restores reproductive hormone balance, and stage-2 sleep, and reduces anxiety and depressive mood.

When Should I Take Melatonin?

The perfect time to take melatonin supplements depends on your needs and goals.

It is generally recommended to take melatonin one to two hours before bedtime. This timing allows your body enough time to absorb the supplement, ensuring it works effectively. The normal adult dosage of melatonin is between 1 to 5 mg, depending on individual needs. Most melatonin supplements take effect in around 20 to 40 minutes post-ingestion.

Is Melatonin Safe?

Yes, melatonin supplements are generally safe. However, adhering to the proper dosages and usage guidelines is important.

When Should I Not Take Melatonin?

Keep in mind that melatonin supplements aren't suitable for everyone. 

  • People with allergic reactions to melatonin supplements: Melatonin is not recommended for people who have previously experienced allergic reactions to the medication.
  • People with autoimmune conditions: Patients with lupus, multiple sclerosis (MS), and rheumatoid arthritis mustn't take melatonin supplements. 

Melatonin can interact with certain prescription medications, including those for preventing seizures, managing diabetes, and controlling blood pressure.

  • Possibly unsafe for pregnant and breastfeeding women: While Johns Hopkins Medicine advises against melatonin supplement use for pregnant or breastfeeding women, a 2022 study found that melatonin supplements caused no harm to the baby.

Talk to a doctor before using melatonin to determine whether these supplements are a good choice for you.

Side Effects of Melatonin

Some individuals might experience side effects of melatonin supplements such as; 

  • Drowsiness
  • Dizziness
  • Nausea
  • Headaches

In rare cases, people taking melatonin may experience severe side effects, including;

  • Mild tremors
  • Depression
  • Confusion

Melatonin FAQs

Is Melatonin Safe to Give to Children?

Yes, evidence shows that when used correctly with the appropriate dose for age and medical expert approval and guidance, melatonin supplements are safe for children.

However, children younger than three should not take melatonin supplements for sleep problems.

Do I Need a Prescription for Melatonin?

In the United States, you can buy melatonin over the counter as a dietary supplement. In other countries, melatonin is labeled as a drug and you can only get it with a prescription.


  1. Buenaver, L. F., Melatonin for sleep: Does it work? Johns Hopkins Medicine.
  2. Burke, T. M., Markwald, R. R., McHill, A. W., Chinoy, E. D., Snider, J. A., Bessman, S. C., Jung, C. M., O’Neill, J. S., & Wright, K. P., Jr. (2015). Effects of caffeine on the human circadian clock in vivo and in vitro. Science Translational Medicine, 7(305), 305ra146.
  3. Cleveland Clinic. (2022). Melatonin. Retrieved from
  4. Fliesler, N. (2022, June 13). Melatonin for kids: Is it effective? Is it safe? Boston Children's Hospital. Retrieved from
  5. Herxheimer, A., & Petrie, K. J. (2002). Melatonin for the prevention and treatment of jet lag. Cochrane Database of Systematic Reviews, (2), CD001520.
  6. Karasek, M. (2004). Melatonin, human aging, and age-related diseases. Experimental Gerontology, 39(11-12), 1723-1729.
  7. National Health Service. (2023, February 13). Who can and cannot take melatonin. Retrieved from
  8. Rausch-Phung, E., & Singh, A. (2023, December 7). Melatonin and sleep: How long does melatonin take to work? Retrieved from
  9. Vine, T., Brown, G. M., & Frey, B. N. (2022). Melatonin use during pregnancy and lactation: A scoping review of human studies. Braz J Psychiatry, 44(3), 342–348.
  10. Yin, W., Zhang, J., Guo, Y., Wu, Z., Diao, C., & Sun, J. (2022). Melatonin for premenstrual syndrome: A potential remedy but not ready. Frontiers in Endocrinology, 13, Article 1084249.

Activity History - Last updated: 11 June 2024, Published date:


David is a seasoned Pharmacist, natural medicines expert, medical reviewer, and pastor. Earning his Doctorate from the Medical University of South Carolina, David received clinical training at several major hospital systems and has worked for various pharmacy chains over the years. His focus and passion has always been taking care of his patients by getting accurate information and thorough education to those who need it most. His motto: "Good Information = Good Outcomes".

Activity History - Medically Reviewed on 08 April 2024 and last checked on 11 June 2024

Medically reviewed by
Dr. David Miles


Dr. David Miles


Ready to talk about treatment? Call us today. (855) 648-7288
Helpline Information
Phone numbers listed within our directory for individual providers will connect directly to that provider.
Any calls to numbers marked with (I) symbols will be routed through a trusted partner, more details can be found by visiting
For any specific questions please email us at

Related articles