Every so often, though, you’ll have a counterproductive day at work and need to pick up the slack before bed. But this situation raises an important question: If you’re going to stay up late working, how do you stay productive?

Below are 21 tips to help keep you productive into the early hours of the morning.

21 Tips to Stay Productive When You're Working at Night

1) Practice yoga or meditation.

Practicing yoga helps alleviate both stress and mental fatigue, resulting in improved productivity and a relaxed mindset. Studies have shown that stress can make us less productive. In light of the data, spending a mere 15 minutes meditating can make an immediate difference in nighttime productivity.

2) Take a break before starting.

Research has revealed that taking regular breaks prior to starting a new project can result in improved productivity. After the work day is over, a small 20-minute relaxation period can play a major role in your productivity during the next few hours.

3) Set a hard deadline.

According to Contently, working on large goals with a tight deadline results in our best work. For example, starting a project at 7 p.m. and establishing a hard deadline of 1 a.m. will improve productivity versus saying, “I’ll get this done tomorrow.”

4) Write down your goals.

Writing down our goals, according to research, immediately makes us more likely to achieve those goals. Prior to your long night, jot down the two to three most important tasks ahead of you for improved productivity.

5) Have a well-timed meal.

While caffeine can give us a mental boost, it’s food that has a direct impact on our cognitive abilities during the last stretch of a day, according to studies. Not eating can set us back cognitively, resulting in less-than-excellent work due to lack of energy.

6) Create a productive playlist.

Several studies have found that music can play a direct role in our productivity as it makes repetitive tasks less annoying, and drowns out the distracting noises of our offices and homes. There are several options for a playlist, but classical music is most likely to improve cognitive functions.

7) Don’t work in your bedroom.

Working in your bed can make your brain associate your bedroom as a place for work, not sleep, according to Lifehack. This association can result in lost sleep in the future and an inability to turn off when we go to bed.

8) Avoid watching television while you work.

Watching television while we work requires our brain to multitask, which can lead to decreased performance and an underwhelming project. Our brains work best when we’re focused on one thing at a time and giving the task at hand our complete attention.

9) Exercise before beginning.

Not a yoga person? Studies have shown that all forms of exercise can increase our cognitive abilities and overall energy. With more energy and a clear mind, we’re likely to produce better results and be more productive.

10) Drink water.

While caffeine might be tempting, a recent study found that drinking water can increase our productivity by as much as 14%. The study found that drinking water helps expand the grey matter in our brains which is key to being more productive.

11) Leave your low effort, low impact goals for the evening.

Instead of trying to accomplish an extremely challenging task at night, focus instead on knocking out small goals as you build up momentum for the day ahead. Prior to your day, run your tasks though an impact versus effort analysis to determine which tasks require little energy but add up in value.

12) Be honest about what you can achieve.

Setting overly ambitious goals can put us on a path for failure, which results in lost productivity and drained willpower. Setting realistic goals allows us to accomplish the tasks, resulting in improved morale and enhanced productivity. In short, don’t bite off more than you can chew at night.

13) Cut off the wifi.

While the internet can be enticing after a long day, blocking it will allow you to tune out distractions like social media and hone in on what matters. If you’re struggling with this, extensions like StayFocused and BlockSite can help.

14) Stand up.

Several studies have found that standing while working results in better concentration, more energy, and fewer headaches. By finding a place to stand and work at home, you can knock off your evening to-do list with ease.

15) Dress in work clothes.

Pajamas might be tempting, but studies have revealed that dressing for work actually heightens our attention and makes us more focused on the task at hand. Instead of sweatpants, try some business attire for max nighttime productivity.

16) Block out distractions.

Although it can be difficult, it’s important to stay in a work mindset to produce the best results. By avoiding the regular things we do at home for the night -- i.e laundry, cleaning the bathroom, watching TV with family -- we’re able to stay in the right mindset to be successful.

17) Have an established work space.

If you’re working late at night, it’s important to have an established work space so you don’t confuse home space with work space. Having a dedicated workspace allows our brains to associate the space with work, according to Wix, which makes us more productive.

18) Use the right kind of light.

Studies have found that our circadian rhythm can be triggered by blue light, increasing our awareness and giving us more energy. The circadian rhythm is what determines our body’s natural energy level. By looking at a blue light, we can give ourselves an energy boost.

19) Take a cold shower.

Although scary at first, a cold shower, according to research, can improve energy levels, help our body rebuild key muscles, and make us feel renewed and fresh. If you can’t bring yourself to take a cold shower right off the bat, try the 911 challenge.

20) Crank up the thermostat.

A study from Cornell University discovered that warmer temperatures decrease the amount of mistakes employees make while improving their output. Cold temperature is mostly associated with sleep, so by turning the heat up, you’re more likely to be alert at night.

21) Reach for some lemon tea.

If all else fails and life hands you lemons, make lemonade (or lemon tea). Studies have shown that the aroma of lemon improves our mood, and stimulates our bodies.

Every once in awhile we can have a slow or distracted day, requiring us to work late. While this isn’t ideal, there are a multitude of strategies we can use to ensure we retain our productivity even after the work day is over.

Have you tried any of these out? Tell us about what keeps you productive when you’re working late in the comments.