Melatonin: What Is It and Can It Help You Sleep?

Medically Reviewed by Jabeen Begum, MD on September 13, 2024
5 min read

Melatonin is a hormone made by the pineal gland. That's a pea-sized gland found just above the middle of your brain. It helps your body know when it's time to sleep and wake up.

Normally, your body makes more melatonin at night. Levels usually start to go up in the evening once the sun sets. They drop in the morning when the sun goes up. The amount of light you get each day and your body clock control how much melatonin your body makes.

You can also buy melatonin supplements. You might find them in natural or synthetic forms. The natural forms are made from the pineal gland in animals.

People use melatonin when they have occasional insomnia — trouble falling asleep and staying asleep. They also take it for some other sleep problems. This could include something called delayed sleep phase disorder. If you have that, falling asleep before 2 a.m. is tough. So is getting up in the morning.

However, melatonin can't take the place of a doctor's care for serious sleep disorders such as obstructive sleep apnea, narcolepsy, or long-term insomnia.

Folks may try melatonin if they have jobs that disrupt typical sleep schedules, a condition called sleep work disorder.

It's also used to treat or prevent jet lag, which is the tired, run-down feeling some get when traveling across time zones.

Doctors are also studying to see if melatonin can help with:

Hypomelatoninemia

Hypomelatoninemia happens when your body makes lower levels of melatonin than what's normal for your age and sex either at night or overall.

Hypermelatoninemia

Hypermelatoninemia is when your body makes more melatonin than normal at night, with levels often staying high into the morning. It mostly happens when you take too much melatonin or melatonin-based sleep medications. It's rare to have high melatonin levels naturally. 

For adults

There's no official suggested dose for melatonin, but most people take between 1 and 5 milligrams about 30 minutes before bed. Supplements are available in doses ranging from 200 micrograms to 20 milligrams. Experts suggest starting with a low dose, such as 1 milligram or less, and raising it only if needed. Lower doses can work as well as higher ones, but the right dose may vary based on things such as your age.

For children

While melatonin supplements are likely safe for children, you should talk to your family doctor first. The dose for kids with insomnia usually depends on their age. Preschoolers can often take 1 to 2 milligrams, school-aged children 1 to 3 milligrams, and adolescents 1 to 5 milligrams. Since melatonin is a hormone and researchers haven't closely studied it in children, there’s a concern it could affect hormonal development.

Doctors can check your melatonin levels by doing blood or urine tests, which show how much melatonin is in your body. Some tests use a small saliva (spit) sample.

Normal melatonin levels

Melatonin levels in the pineal gland change based on your age and sex. Here's what they can look like throughout your life:

Newborns. Babies don't make their own melatonin. Before birth, they get it from the placenta and, after birth, through breast milk. Melatonin production starts when they are 2 to 3 months old.

Children. Melatonin levels rise as you grow, peaking just before puberty.

Puberty. After puberty begins, melatonin levels drop steadily until they level off in your late teens.

After puberty. Women and people assigned female at birth (AFAB) have higher melatonin levels than men and people assigned male at birth (AMAB).

Middle age. Melatonin levels stay stable until around age 40, then begin to fall.

Older adulthood. Melatonin levels in people over 90 are less than 20% of what they are in young adults.

Factors affecting melatonin decline with age include:

  • Calcification of the pineal gland (common with aging)
  • Problems detecting light due to eye conditions such as cataracts

If you get a melatonin level test, your doctor will interpret the results based on your age and sex.

While melatonin generally causes fewer side effects than other sleep medicines, you could still have:

Melatonin supplements might cause problems if you take them with some medicines, including:

Tell your doctor if you're thinking about taking any supplements, especially if you take any medicine or have a health condition.

The natural form of melatonin might have a virus or other risks, so pick a synthetic type instead.

Nonsteroidal anti-inflammatory drugs (NSAIDs) are medicines commonly used to ease pain, inflammation, and fever. Ibuprofen is an example of an NSAID. These drugs may affect melatonin, lowering its amount in the blood, which might impact sleep patterns, especially if used a lot or in high doses.

If you're having intense or strange dreams after taking melatonin, it may be because melatonin helps you sleep deeper. When you sleep deeper, you spend more time in rapid eye movement (REM) sleep, the stage where most vivid dreams happen. More time in REM sleep can lead to more intense dreams.

Melatonin also releases a protein called vasotocin, which controls REM sleep. Higher melatonin levels can mean more vasotocin, leading to more REM sleep and more vivid dreams. 

Everybody reacts differently to medicines and supplements, so melatonin may or may not work for you.

Some studies say it could help with jet lag and some sleep issues such as delayed sleep phase disorder, shift work disorder, and some sleep disorders in children.

Other research shows it may let people with insomnia fall asleep slightly faster. It may also help you sleep better through the night but not necessarily longer.

Still, more studies have shown that melatonin doesn't help with sleep problems at all. There's also not enough research to say it helps with issues other than sleep.

The pineal gland in the brain makes melatonin, a hormone that controls your sleep-wake cycle by rising at night and dropping during the day. People can take melatonin supplements to help with occasional insomnia, jet lag, or sleep issues related to shift work. Melatonin supplements can help with certain sleep problems, but they don't replace medical care for serious sleep disorders such as sleep apnea or narcolepsy. 

Melatonin levels naturally drop with age. Taking too much melatonin or using certain medications can cause side effects such as daytime sleepiness, dizziness, or stomach discomfort. Talk to your doctor before using melatonin, especially for children or people with existing health conditions.

How long does it take for melatonin to work?

Melatonin supplements usually start working within 20 to 40 minutes of taking them.