You tossed and turned all night and couldn't sleep, so when you get up you power guzzle some java to feel alive. It's not going to work.

Researchers have found that a jolt of caffeine isn’t enough to replace lost rest.

Research from Michigan State University looks into how effective caffeine is at making up for a sleepless night and the cognitive toll it takes and it turns out, there’s nothing that can replace those hours of sleep, no matter how much coffee you drink.

After staying up all night, 275 study participants were asked to complete a simple attention task and a more challenging “placekeeping” task. The more complex assignment involved finishing tasks in a specific order, without skipping or repeating any of the prior steps.

 

And while the lack of sleep negatively affected both types of tasks, caffeine did help people successfully finish the easier task. But the harder one? Study authors say caffeine had little effect on those.

So while coffee can give us a boost of energy to perk us up, it’s not the magic fix to make up for a lack of precious sleep.

 

“Caffeine may improve the ability to stay awake and attend to a task, but it doesn’t do much to prevent the sort of procedural errors that can cause things like medical mistakes and car accidents,” explains study author Kimberly Fenn.

She says people may feel like they’re combating sleep deprivation with caffeine, but their higher-level tasks - like driving - will probably still be impaired, which is one of the reasons sleep deprivation can be so dangerous.

KEEP READING: 15 Natural Ways to Improve Your Sleep