What Causes Morning Erections? REM Sleep and Testosterone

Morning erections are caused by a combination of REM sleep activity, nervous system changes, and hormonal rhythms that work together during the night. They are not typically triggered by sexual arousal or dreams, though those can occasionally play a role. Healthy men experience three to five erections per night, each lasting roughly 10 to 25 minutes, and the one you notice when you wake up is simply the last in that series.

The REM Sleep Connection

The primary driver of nighttime erections is REM sleep, the phase of sleep associated with vivid dreaming and high brain activity. During REM, your brain dramatically reduces the release of norepinephrine, a chemical that normally keeps certain body functions in check, including keeping the penis in its non-erect state. When that chemical brake is lifted, the parasympathetic nervous system (the “rest and digest” side of your nervous system) takes over and promotes blood flow to the penis.

You cycle through REM sleep multiple times each night, with the longest REM periods happening in the final hours before waking. That’s why the last erection of the night often coincides with your alarm going off. It’s not that morning itself triggers the erection. You’re just catching the tail end of a process that’s been repeating all night.

How Blood Flow Creates the Erection

During REM sleep, nerve endings in the erectile tissue release nitric oxide, a signaling molecule that relaxes the smooth muscle in the walls of penile blood vessels. This relaxation allows blood to rush in and fill the spongy chambers of the penis, producing rigidity. The endothelial cells lining those blood vessels also contribute nitric oxide, reinforcing the effect. As long as the REM period lasts, the blood stays trapped and the erection is maintained. Once REM ends and norepinephrine rises again, the blood vessels constrict and the erection subsides.

The Role of Testosterone

Testosterone follows a circadian rhythm tied to sleep. Levels are at their lowest in the evening and climb steadily overnight, peaking between about 7 and 10 a.m. This hormonal surge doesn’t directly cause each individual erection, but it sets the stage. Men with healthy testosterone levels tend to have more frequent and firmer nighttime erections, while men with significantly low testosterone often notice fewer morning erections or none at all.

This is one reason sleep quality matters so much. Conditions like sleep apnea are associated with lower testosterone levels, which in turn reduces the frequency of nighttime and morning erections. In many cases, treating the sleep disorder and restoring consistent, deep sleep brings testosterone levels back up and erections along with them.

Why Your Body Does This

Researchers have debated the biological purpose of nighttime erections for decades, and the answer still isn’t fully settled. The leading theory is tissue maintenance. During an erection, oxygen-rich blood floods into erectile tissue that otherwise receives relatively low blood flow. This regular influx of oxygen may prevent the buildup of scar-like tissue (fibrosis) in the spongy chambers of the penis, keeping the tissue elastic and functional over time. Think of it as the body’s way of keeping the machinery in working order, even when it’s not being used.

What Changes With Age

Nighttime erections begin well before puberty and continue throughout life, but their frequency, firmness, and duration gradually decline with age. A healthy young man might have four or five episodes per night, with some lasting up to 25 minutes or longer. By middle age, the number and duration tend to decrease, though they don’t disappear entirely in healthy individuals. The decline tracks with age-related changes in sleep architecture (older adults spend less time in REM sleep), gradual decreases in testosterone, and changes in blood vessel health.

When Morning Erections Disappear

A noticeable drop in morning erections can be a useful signal. The American Urological Association includes questions about morning and nighttime erections as part of evaluating erectile dysfunction. The logic is straightforward: if your body still produces erections during sleep, the physical plumbing (blood vessels, nerves, hormones) is likely working, and difficulty with erections during sex may have a psychological component, such as anxiety or stress. If nighttime erections have also disappeared, that points more toward a physical cause like vascular disease, nerve damage, or hormonal imbalance.

Clinicians can measure this formally using a device that records the number, rigidity, and duration of erections over several nights of sleep. But for most men, simply paying attention to whether morning erections are happening, and how often, provides a rough but useful gauge of overall erectile and cardiovascular health.

Several factors can reduce or eliminate morning erections beyond aging. Poor sleep quality, high stress, heavy alcohol use, certain medications (particularly antidepressants and blood pressure drugs), obesity, and diabetes all interfere with either the hormonal, vascular, or neurological pathways that make nighttime erections possible. In many of these cases, addressing the underlying issue restores them.