If you are tossing and turning, restlessly moving throughout the night, you may want to try a different type of movement before crawling into bed. Exercise and sleep are intertwined, influencing each other. Let’s explore how to sweat your way to a restful night and sleep your way to a more energized workout.

Why exercise helps us sleep better…and vice versa

Regular exercise is profoundly beneficial to your sleep. People who exercise regularly report better sleep quality than those who don’t. Physical activity can increase the amount of time we spend in deep sleep, the most restorative sleep stage. Fitness can also reduce sleep onset time, allowing you to fall asleep faster once your head hits the pillow. Exercise increases sleep duration, boosting the number of hours you are able to sleep and decreasing the time spent lying awake in the middle of the night.

Sleep and exercise have a bidirectional relationship. Based on the available data, researchers theorize that poor sleep may be a key impediment to achieving a physically active lifestyle, and a good night’s sleep can help you feel more motivated to take on a workout the next day. Those with insomnia and sleep disorders, as well as some people who sleep poorly, are less active and less likely to exercise during the day.

Alternatively, better quality, longer sleep could improve your workout or athletic performance, like it did for Stanford University basketball players. It is important to note that though studies have established a relationship between good sleep and healthy physical activity levels, the current research has not yet conclusively proven that better sleep directly leads to an increase in physical activity in all cases.

The best time to exercise to improve sleep

Exercising right before bed may not be a good idea…If you’re a fitness freak taking on heavy heart-pounding workouts, a pre-bed workout may not be the best nighttime routine. You could activate stimulating hormones such as endorphins, which increase brain activity and can keep some people awake. In addition, exercise increases core body temperature, which typically needs to fall in order to signal to your brain that it’s bedtime. If you prefer to exercise in the evenings but it’s making it more difficult to fall asleep, carve out gym time at least 1-2 hours before bed to give your brain plenty of time to wind down.

Find the right time for you. It’s a common misconception that early morning workouts help improve productivity throughout the day, but the crack of dawn timeframe isn’t for everyone. Sleep educator Frida Rångtell, PhD emphasizes that everyone is different, and the “best” time of day to get the optimal workout in varies from person to person: “Although exercising is good for the brain and body, [early mornings] aren’t for everyone. Some individuals need to sleep a little later in the morning and people tend to perform their best at different times of the day. If you’re an evening person, you may perform better later in the day and vice versa for morning people.”

When it comes to exercise, habit and regularity may matter more than the time of day you’re working out. Experiment with your fitness timing to find the one that works best for you.

Sleep helps with post-workout recovery

Sleep naturally helps our body to heal and recover and is especially necessary after grueling workouts. Most adults need an average of 8 hours of sleep per night, but if you’re exercising frequently and straining your muscles, you may need more than 8 hours of sleep to make sure you’re able to properly recover. You will be able to tell that your body needs more sleep if you are experiencing excessive daytime sleepiness, if you are consistently having trouble focusing, if you fall asleep easily during the day in non-traditional scenarios, or if you are oversleeping often.

Exercises for better sleep

You do not need to do much before you’ll start to feel the benefits of exercise. Just 30 minutes a day can be enough to improve your sleep. Track your workouts in the Sleep Cycle app to see how your workouts are impacting your slumber. It may take some experimentation to find the type of physical activity that is most compatible with your sleep, but some experts recommend the following:

  • Resistance exercises: Studies have shown that resistance exercises can improve sleep. These include weightlifting, squats, push-ups, and lunges.
  • Yoga: Yoga has a number of benefits that can improve sleep. It can increase mindfulness and encourage meditation, putting you in a more peaceful mental state for sleeping. The deep rhythmic breathing and intentional movement can also aid with sleep.
  • Moderate intensity aerobic activities: Activities such as brisk walking, water aerobics, and semi-hilly bike rides get your heart rate up without activating chemicals that can keep you from falling asleep.

The next time you are struggling to find motivation to exercise, think about it this way: you are giving yourself the gift of a good night’s sleep. Keep at it and you will soon be flexing well-rested muscles.