How sleep turns the day's learning into memory

Sleep is not downtime for memory. In deep sleep the hippocampus replays what you learned and hands it to the cortex, which is why an all-nighter before an exam costs more than it gains.

Henri Rousseau painting The Sleeping Gypsy: a woman asleep in a desert under the moon while a lion stands over her
Photo: Henri Rousseau, Public domain, via Wikimedia Commons

Sleep turns learning into memory mainly during deep, slow-wave sleep, when the hippocampus replays the day's new memories and the brain's slow oscillations coordinate their transfer into long-term storage in the cortex. Later REM sleep appears to help stabilise what was transferred. Losing sleep hurts twice: memories from the day before consolidate less, and a sleep-deprived brain encodes new material less well the next day.

Key takeaways
  • Slow-wave sleep, concentrated early in the night, is when the hippocampus replays new memories to the cortex.
  • 1994: rat place cells that fired together by day fired together again in sleep (Wilson and McNaughton).
  • An odour cue replayed during deep sleep, and only then, improved recall of facts (Rasch 2007).
  • 4.7 → 2.8 words recalled after normal sleep vs 35 hours awake (Drummond 2000).
  • 59% of Indians in a 2025 survey get under six hours of uninterrupted sleep.

For anyone preparing for boards, JEE, NEET or a semester exam, this is the practical point: the hours spent asleep after studying are part of studying. The evidence comes from three directions:

  1. animal recordings of neurons replaying experience during sleep;
  2. human experiments that manipulate sleep or cue memories during it;
  3. imaging of what a sleepless brain does when it tries to learn.

A fourth line, the brain's fluid "clean-up" during sleep, is real research but more contested than its popularity suggests, and I cover the disagreement at the end.

59%of Indians in a 2025 survey of 43,000+ get under 6 hours of uninterrupted sleep (LocalCircles)
~90 mintypical length of one adult sleep cycle; about five cycles in 7-8 hours
4.7 → 2.8words freely recalled after normal sleep vs after 35 hours awake (Drummond 2000)
14% → 23%brain interstitial space, awake vs asleep, in mice (Xie 2013)

What happens to memories while you sleep?

The story

The first systematic test of sleep and memory used two people who more or less moved into a psychology laboratory. In a study published in 1924, J. G. Jenkins and Karl Dallenbach had two participants, identified as H. and Mc., live in the lab for about two months, learning lists of nonsense syllables by day and by night.

After each list came a gap of 1, 2, 4 or 8 hours, filled either with ordinary waking life or with sleep, in random order, with six to eight trials per interval. At every interval, recall after sleep beat recall after the same time awake. Their reading was that forgetting is not simple decay with time; waking activity interferes with fresh memories, and sleep shields them. It took decades to show that sleep does more than shield.

Rasch and Born: About sleep's role in memory, Physiological Reviews 2013 (history section)

New memories are reactivated and reorganised. The leading account, which Bjorn Rasch and Jan Born set out in a 2013 review in Physiological Reviews, is called active system consolidation. During waking, the hippocampus quickly encodes new experiences as a temporary store. During slow-wave sleep (SWS), those representations are repeatedly reactivated, and the reactivation transforms them and integrates them into long-term networks in the neocortex. Subsequent REM sleep may then stabilise the transformed memories.

Older theories saw sleep as passive protection: memories survived because nothing new interfered with them overnight. The review argues the evidence now favours an active role, and that sleep is a brain state optimised for consolidation, in contrast to waking, which is optimised for encoding. That split explains why cramming late into the night is a poor trade: it takes time from the consolidation state to add more to an encoding state that is already tired.

Waking is optimised for encoding; sleep is optimised for consolidation. An all-nighter borrows from the second to overload the first.
REMN1N2N2/N3N3 sleep onsetmorning replay in slow-wave sleep longer REM later in the night A night in about five cycles (schematic)
A simplified night. Deep slow-wave sleep is concentrated in the first cycles, when most hippocampal replay is thought to happen; REM periods lengthen towards morning. Real nights are messier.
StageWhen it dominatesSignature activityProposed memory role
N1 (light)Transitions, briefDrifting, slowing EEGLittle direct role
N2Throughout the nightSleep spindles from the thalamusSpindles couple with hippocampal ripples; evidence on spindles and memory is mixed
N3 (slow-wave sleep)Early nightLarge slow oscillations; hippocampal sharp-wave ripplesReplay and transfer of new declarative memories to cortex
REMLate night, longer each cycleWake-like EEG, muscle atoniaMay stabilise transformed memories; linked to procedural gains in late-night sleep

Use this to check what you just read: how many full cycles fit into the time you actually spend in bed, and how much of the night is likely spent getting to sleep.

How many sleep cycles does your night allow?

About Sleep's Role in MemoryBjorn Rasch, Jan Born · Physiological Reviews 93(2) · 2013

An 86-page review of more than a century of sleep and memory research. It traces the shift from passive theories (sleep protects memories from interference) to active system consolidation, in which recently encoded hippocampal memories are reactivated during slow-wave sleep and redistributed to long-term cortical stores, with REM sleep possibly stabilising them. It covers the electrophysiological, neurochemical and genetic mechanisms and extends the idea to non-hippocampal and even immunological memory. The limit: much of the mechanistic evidence comes from rodents, and the exact role of each sleep rhythm in humans is still debated.

Read the paper (free)

What is hippocampal replay?

Replay is the hippocampus re-running patterns of neural activity from waking experience during sleep. The first clear evidence came from Matthew Wilson and Bruce McNaughton, who in 1994 recorded large groups of hippocampal place cells in three rats, both while the animals ran spatial tasks and during the slow-wave sleep before and after.

Cells that fired together when the rat was in particular places showed a stronger tendency to fire together in the sleep after the task than in the sleep before it. Cells that had not been co-active during the task showed no such increase, and the effect faded gradually across each post-task sleep session.

Later work found that replay happens in fast bursts called sharp-wave ripples, in which a large share of hippocampal neurons fire together within a fraction of a second, and that the replayed sequences are compressed in time several-fold compared with the original experience. The hippocampus is effectively replaying the day at speed, and the cortex is listening.

From hippocampus to cortexActive system consolidation (Rasch and Born 2013)Day: encodinghippocampus stores a fast,temporary copy of newfacts and eventsCortexslow learner; long-termstore integrated withwhat you already knowNight, slow-wave sleep: replay1. cortical slow oscillation opens a window (up-state)2. thalamic spindle couples to it3. hippocampal sharp-wave ripple replays the memory, time-compressed4. repeated many times: the cortical trace strengthensLate night, REMmay stabilise the transformed memory (still debated)
The proposed route of a new memory. Encoding by day, replay coordinated by three sleep rhythms early in the night, and possible stabilisation in REM towards morning.
Rendering of the human brain with the hippocampus highlighted deep in the temporal lobe
The hippocampus, highlighted here in a standard brain atlas, sits deep in each temporal lobe. It stores new episodes quickly and, during slow-wave sleep, replays them to the cortex.Photo: RAZVAN V. MARINESCU, CC BY 4.0, via Wikimedia Commons
Reactivation of Hippocampal Ensemble Memories During SleepMatthew A. Wilson, Bruce L. McNaughton · Science 265 · 1994

Simultaneous recordings from large ensembles of hippocampal place cells in three rats, during spatial behaviour and during slow-wave sleep before and after it. Pairs of cells that fired together during behaviour fired together more in the following sleep than in the preceding sleep; cells with no overlap did not. The effect declined over each post-behaviour sleep session. The authors concluded that information acquired while awake is re-expressed in hippocampal circuits during sleep, as consolidation theories predicted. The limit: three animals and correlational co-firing, so it showed replay exists but not that it causes better memory.

Read the paper

Can you prove that replay causes better memory?

Yes, and the cleanest human demonstration used a smell. Rasch, Christian Buchel, Steffen Gais and Born had people learn while an odour was present as part of the learning context. Re-presenting the same odour during the participants' slow-wave sleep improved their retention of hippocampus-dependent declarative memories.

The controls are what make it convincing. The cue did nothing:

  • for a procedural skill;
  • when given during REM sleep or while awake;
  • if the odour had not been present during learning.

Functional MRI showed the hippocampus responding to the odour during slow-wave sleep.

That pattern, a benefit only in SWS and only for hippocampal memories, is exactly what active system consolidation predicts. It moved the field from "sleep is associated with better memory" to "reactivating a memory during deep sleep strengthens it".

Odor Cues During Slow-Wave Sleep Prompt Declarative Memory ConsolidationBjorn Rasch, Christian Buchel, Steffen Gais, Jan Born · Science 315 · 2007

Participants learned declarative and procedural tasks with an odour present as context. Re-exposure to the odour during slow-wave sleep improved retention of the hippocampus-dependent memories but not of a procedural skill. The odour was ineffective during REM sleep, during wakefulness, or when it had been absent at learning, and fMRI showed significant hippocampal activation to the odour during SWS. The limit: a lab task with a specific cue; the size of the effect for real study material, and whether cueing can be used safely at home, are still open.

Read the paper

What does an all-nighter do to learning?

It weakens both sides of memory: consolidation of what you learned the day before, and encoding of what you try to learn the next day. Seung-Schik Yoo, Matthew Walker and colleagues at Harvard showed in 2007 that a single night of sleep deprivation produced a significant drop in hippocampal activity while people tried to encode new episodic memories, and they remembered less later. Sleep before learning, not just after, prepares the brain to take in new memories.

Sean Drummond's group at UC San Diego scanned young adults learning word lists after 35 hours without sleep. Free recall was significantly worse than after normal sleep, about 2.8 words against 4.7 in one measure.

The prefrontal cortex actually worked harder in the deprived state, and people who recruited more parietal cortex recalled more, which suggests the tired brain compensates but only partly. A student who stays up through the night before an exam is studying with a brain that is both less able to store the new material and has skipped the night that would have consolidated the old.

Brain interstitial space in mice: awake vs asleep or anaesthetised
See the data as a table
Interstitial volume fraction (% of tissue volume)
Awake (evening)14.1
Natural sleep23.4
Awake (same mice)13.6
Ketamine/xylazine22.7

Source: Xie et al., Science 2013 · Sleep n=6 mice; anaesthesia comparison n=10 mice, paired. A 2024 study disputes that this speeds clearance.

Does sleep wash toxins out of the brain?

A widely cited 2013 mouse study said yes, and a 2024 mouse study said the opposite, so treat this as unsettled.

The 2013 "glymphatic" result

Lulu Xie, Maiken Nedergaard and colleagues measured the space between brain cells in live mice and found it was about 13 to 15% of cortical volume when awake and 22 to 24% when asleep or anaesthetised, a rise of more than 60%.

Cerebrospinal fluid tracer influx was about 95% lower in awake mice than in sleeping ones, and beta-amyloid was cleared about twice as fast during sleep. Blocking noradrenaline signalling in awake mice enlarged the space, which pointed to noradrenaline as the switch. This "glymphatic" account became one of the most quoted reasons to sleep.

The 2024 challenge and the 2025 reply

In 2024 Andawei Miao, Nicholas Franks, William Wisden and colleagues at Imperial College London measured the movement of fluorescent molecules in mouse brains directly. They reported that movement did not depend on sleep, wake or anaesthesia, and that clearance was markedly reduced, not increased, during sleep and anaesthesia.

In January 2025 a paper in Cell led by Natalie Hauglund, with Nedergaard as senior author, reported that during deep sleep the brainstem releases noradrenaline in pulses roughly every 50 seconds, which make blood vessels contract and relax and push fluid through the brain; the sleeping pill zolpidem cut those waves by about half and fluid transport by more than 30% in mice.

The memory story above does not depend on the clean-up story; the replay and cueing evidence stands either way.

Sleep Drives Metabolite Clearance from the Adult BrainLulu Xie, Hongyi Kang, Qiwu Xu, Michael J. Chen et al., Maiken Nedergaard · Science 342 · 2013 (University of Rochester)

Using tetramethylammonium diffusion measurements and two-photon imaging in live mice, the authors found the interstitial volume fraction was 23.4% in sleeping mice (n=6) against 14.1% in mice awake in the evening, and rose from 13.6% to 22.7% in the same mice after ketamine/xylazine anaesthesia (n=10). Tracer influx was about 95% lower when awake, and beta-amyloid cleared twice as fast during sleep. The limit: mice, anaesthesia as a stand-in for sleep in part of the work, and a 2024 Imperial College study using a different method found clearance falls during sleep.

Read the paper (free)

How much do Indians sleep, and what does that mean for students?

Less than the memory research would recommend. LocalCircles' "How India Sleeps 2025" survey, with more than 43,000 respondents in 348 districts released in March 2025, found that 59% get under six hours of uninterrupted sleep. Among those with disrupted sleep, the most common reason was waking to use the washroom (72%), followed by poor schedules (25%) and noise and mosquitoes (22%); phone calls and messages were only 6%. It is an online survey, not a clinical sleep study, but the direction is clear.

For students, the practical rules follow from the mechanism:

  • Study, then sleep. The first part of the night carries most slow-wave sleep, so a full night after a study session is when the day's material is replayed.
  • Sleep before you learn, too. A rested hippocampus encodes better; the all-nighter damages the next day's intake as well as yesterday's.
  • Protect the whole night. Five cycles over 7-8 hours give both early slow-wave sleep and late REM; cutting the morning cuts REM.
  • Pair sleep with retrieval. Testing yourself before sleep and again in the morning is a strong combination; methods are ranked in study techniques ranked by evidence.

If you cannot sleep even when you try, the evidence-based treatment is cognitive behavioural therapy for insomnia, covered in how to sleep better with CBT-I. Why memory has a small workspace to begin with is in working memory and the four-item limit, and the stress side of exam season in India is in exam stress in India.

Thomas Stothard painting of a nymph asleep in a woodland setting
Thomas Stothard, A Nymph Sleeping. Painters treated sleep as rest; the lab work of the last 30 years shows it is also when the brain does much of its filing.Photo: Thomas Stothard, Public domain, via Wikimedia Commons

Questions people ask

Is pulling an all-nighter before an exam ever worth it?

Rarely. A night without sleep cuts consolidation of what you studied the day before and reduces the hippocampus's ability to encode new material, with measurably worse recall after 35 hours awake. Sleeping and reviewing briefly in the morning usually beats the extra hours.

Do naps help memory?

They can. Naps that include slow-wave sleep give the hippocampus a chance to replay recent learning. In one study cited in the sleep and memory literature, a 60 to 90 minute nap improved a motor skill immediately, though nappers and non-nappers ended up similar after a full night's sleep.

Which sleep stage matters most for memory?

For facts and events, slow-wave sleep early in the night, when hippocampal replay and transfer to the cortex are concentrated. REM, which lengthens towards morning, appears to help stabilise memories and has been linked to gains in procedural skills. Both matter, which is why the whole night counts.

Does sleep really clean toxins from the brain?

The evidence is split. A 2013 mouse study found the space between brain cells grew by over 60% in sleep and amyloid cleared twice as fast; a 2024 mouse study using a different method found clearance fell during sleep. Human data are still limited.

Sources

  1. Rasch B, Born J. About sleep's role in memory. Physiological Reviews 93(2):681-766 (2013)
  2. Rasch B, Born J. About sleep's role in memory, free full text on PMC (history section: Jenkins and Dallenbach's experiment) (2013)
  3. Ministry of Health and Family Welfare: Tele MANAS, National Tele Mental Health Programme
  4. Wilson MA, McNaughton BL. Reactivation of hippocampal ensemble memories during sleep. Science 265:676-679 (1994)
  5. Rasch B, Buchel C, Gais S, Born J. Odor cues during slow-wave sleep prompt declarative memory consolidation. Science 315:1426-1429 (2007)
  6. Yoo SS, Hu PT, Gujar N, Jolesz FA, Walker MP. A deficit in the ability to form new human memories without sleep. Nature Neuroscience 10:385-392 (2007)
  7. Drummond SP et al. Altered brain response to verbal learning following sleep deprivation. Nature 403:655-657 (2000)
  8. Xie L et al. Sleep drives metabolite clearance from the adult brain. Science 342:373-377 (2013)
  9. Miao A et al. Brain clearance is reduced during sleep and anesthesia. Nature Neuroscience 27:1046-1050 (2024)
  10. ScienceDaily: Hauglund et al., norepinephrine-mediated slow vasomotion drives glymphatic clearance during sleep (Cell) (2025)
  11. ThePrint: 59% of Indians get less than 6 hrs of sleep, LocalCircles survey finds (2025)
  12. Wikipedia: Sleep and memory (sharp-wave ripples, early vs late sleep, Drummond recall figures) (accessed 2026)
  13. Wikipedia: Sleep cycle (cycle length, cycles per night) (accessed 2026)
sleep and memorymemory consolidationslow-wave sleepREM sleephippocampal replayglymphatic systemall-nighterexam preparation
Sapta

Sapta (Saptarshi Sarkar) is a mechanical engineer turned marketer in Bengaluru and a solo touring rider. He writes the seven Saptaverse blogs. Work with him or read more of Mindblog.

Keep reading in Mindblog

From the other blogs