The team at Harvard University found that people who learned a new skill, and then slept well, were better at the task the next day.
"We would train people in the evening before they went to bed in our sleep lab, and record their sleep across the night, and the next morning wake them up and test them and, lo and behold, they would be 20 percent better on average," Matthew Walker, the neuroscientist who led the study, said in a telephone interview.
The idea that sleep helps learning is nothing new, but Walker's team, writing in the July 3 issue of Neuron, said they had shown how much it helps.
"We tested about 62 subjects in total in various small experiments," Walker said.
"The group trained in the morning and then re-tested 12 hours later were able to improve their performance by about 2 percent," he said.
"The performance of those trained in the evening and re-tested 12 hours later, after a good night's sleep, improved far more significantly -- an average of 20 percent."
The test was simple -- they had to use their non-dominant hand and type out a repeated sequence of keys on a computer keyboard.
"What they had to do was try and execute ... that particular sequence over and over again as quickly and accurately as possible," Walker said.
When the researchers analyzed the sleep pattern, they found a once-overlooked phase of sleep, called stage 2 sleep, seemed particularly important.
This is the stage everyone goes through when heading into deep, restorative sleep, and then back up into rapid-eye movement, or REM sleep -- the stage during which dreaming occurs.
"You spend about 50 percent of your night in stage 2 non-REM sleep," Walker said.
Then the researchers looked at timing.
"What we found is that the most critical time, it seemed, for this learning is in the last quarter of the night. Let's live in a fantasy world where we all get eight hours of sleep -- that would make the last two hours the most important," he added.
"This is the part of a good night's sleep that many people will cut short by getting up early in the morning."
The results could benefit athletes, musicians, surgeons -- anyone learning tricky new motor skills that have to be rehearsed.
"When somebody suffers a stroke, they generally have to undergo a process of rehabilitation. That period of intense re-learning may also benefit from a good night of sleep," Walker said.
It may also explain why babies sleep so much.
"They go through intense learning, especially skilled motor actions," Walker said. "It's something they will spend the vast majority of time doing. That intensive learning could be the reason why they have such a hunger ... for many hours of sleep."
By Maggie Fox