Why men get morning wood.

Is there an actual reason the body does that?
Morning wood is common and indicates a normal blood and nerve supply to the penis [1]. Sometimes when you wake up, the sacral nerve controls your erections, and the parasympathetic nervous system is active while your body rests and repairs itself [3]. As a result, you may experience an erection several times during the night [2]. Unrelated to what’s in your dreams, NPT can last up to and even longer than 30 minutes [2]. Some men may experience an erection as long as two hours during their sleep [2]. Having an erect penis when you wake up is an indicator of healthy blood and nerve supply to the penis [2]. The presence of NPT also likely indicates that you’re physically capable of getting and maintaining an erection while awake [2]. If you stop experiencing NPT or notice that you’re not waking up with an erect penis anymore, this may be an early sign of an underlying medical problem [2].
Morning wood is common, especially among young men. Most young men will experience morning wood several times per week and as men grow older, they begin experiencing it less frequently [1]. Many people assume a morning erection is a sign of sexual stimulation, however this isn't always the case [2]. Morning wood is likely the response your body has to one of several natural occurrences [2]. The cause of NPT is likely multifactorial, but doctors do have a few theories that help explain why men wake up with an erect penis from time to time [2]. One theory is physical stimulation, such as if a partner accidentally touches or graze your genitals, you may become erect. Your body senses the stimulation and responds with an erection [2]. Another theory is hormone shifts, your testosterone level is at its highest in the morning after you wake up [2]. It is highest immediately after waking up from rapid eye movement (REM) sleep stage [2]. Additionally, brain relaxation can also cause NPT, as during your waking hours, your body releases hormones to suppress erections, but when you're asleep, your body releases less of those hormones [4]. 