Sleep shows up when the nervous system is in the resting state.
Revving up the nervous system before bed can interfere with sleep.
Exercising’s effect on body temperature can produce sleep challenges.

Cavan Images / Getty Images
Typically, your body temperature decreases as your body prepares for sleep.
However, exercising before bed can increase your core body temperature and disrupt this natural process.
Pay attention to how your body responds to exercise.

Pre-bedtime activities should not be vigorous or engaging enough to make the body and mind more alert.
However, it is best to exercise in themorningor afternoon.
Summary
Working out in the morning or afternoon improves sleep.
2023;15(7):e41638.
doi:10.7759/cureus.41638
Johns Hopkins Medicine.Exercising for better sleep.
2011;4:447. doi:10.2147/IJGM.S18837
Szymusiak R.Body temperature and sleep.Handb Clin Neurol.
2018;156:341-351. doi:10.1016/B978-0-444-63912-7.00020-5.
Sleep Foundation.Bedtime routines for adults.
American Heart Association.American Heart Association recommendations for physical activity in adults and kids.
Harvard Health Publishing.Does exercising at night affect sleep?