Why Your Anxiety and Memory Problems Might Both Stem From Sleep—And How to Break the Cycle

Story-at-a-Glance: Why Your Anxiety and Memory Problems Might Both Stem From Sleep—And How to Break the Cycle
- Anxiety doesn’t just “affect” working memory—it actively competes for the same limited cognitive resources in your brain’s phonological loop and visuospatial sketchpad, creating a dual-task scenario that disrupts sleep
- Research analyzing over 22,000 individuals demonstrates a reliable connection between anxiety and reduced working memory capacity, with effects spanning verbal, spatial, and visual memory systems
- The bidirectional relationship between sleep deprivation and cognitive dysfunction creates a compounding problem where poor sleep worsens anxiety, which further degrades working memory, which then makes falling asleep even more difficult
- Understanding the specific mechanisms—including how worry hijacks your brain’s central executive and overwhelms temporary storage systems—reveals why traditional relaxation techniques often fall short
- Breaking this cycle requires addressing the cognitive load itself, not just treating anxiety or insomnia as separate problems
Have you ever laid in bed at 2 AM, mentally replaying a conversation from earlier that day, analyzing every word choice, every facial expression, every possible interpretation? You’re not just anxious—you’re experiencing what neuroscientists call a working memory competition. Your brain’s limited cognitive resources are being hijacked by anxiety. This same mechanism that’s keeping you awake is also the reason you forgot where you parked your car this morning.
The effects of anxiety on working memory capacity represent far more than academic curiosity. They explain why, when you’re anxious, you can’t remember simple instructions. They explain why you read the same paragraph three times without absorbing it. And they explain why sleep becomes maddeningly elusive even when you’re exhausted.
The Resource Competition That’s Stealing Your Sleep
Working memory isn’t a single entity—it’s a sophisticated system with multiple components, originally conceptualized by Alan Baddeley and Graham Hitch in 1974. The system includes the phonological loop (handling verbal and acoustic information) and the visuospatial sketchpad (processing visual and spatial data). It also includes the central executive (coordinating everything and controlling attention).
Here’s where things get interesting: anxiety doesn’t politely wait its turn. When you’re lying in bed worrying about tomorrow’s presentation, that worry is actively using your phonological loop. This is the same system you’d use to remember a phone number or follow verbal instructions. It’s as if anxiety is a demanding houseguest who won’t stop talking. This makes it impossible for you to think clearly or, crucially, to quiet your mind enough to sleep.
Tim P. Moran’s comprehensive meta-analysis examining 177 samples with over 22,000 individuals revealed something striking: self-reported anxiety consistently correlates with poorer working memory performance across all types of memory tasks. The effect size (g = -.334) held steady across different task types. This was true whether researchers tested simple span tasks like digit recall, complex span tasks requiring both storage and processing, or dynamic tasks like the n-back test. This isn’t a fluke—it’s a fundamental relationship.
But this creates a cascading problem. As research from Stanford Medicine demonstrates, when working memory is compromised, emotional regulation suffers. You can’t effectively process the day’s events or put worries in perspective. You also can’t engage the cognitive control needed to redirect your thoughts away from anxiety-provoking content. This creates what researchers call a state of hyperarousal—your mind is simultaneously overtaxed and unable to power down.
Understanding how sleep impacts your mental health is crucial. Why Your Anxiety and Memory Problems Might Both Stem From Sleep—And How to Break the Cycle is a vital consideration.
How Your Brain’s Filing System Gets Overwhelmed
Think of the phonological loop as your brain’s temporary notepad for verbal information, constantly refreshing through silent rehearsal. Now imagine trying to use that same notepad to simultaneously hold your grocery list. At the same time, you’re mentally rehearsing all the ways a future conversation could go wrong. Something has to give.
Studies examining the visuospatial sketchpad reveal a similar pattern. This component handles visual imagery and spatial relationships—like mentally rotating an object or remembering where you parked. When anxiety floods the system with intrusive visual imagery (replaying embarrassing moments, imagining worst-case scenarios), the visuospatial sketchpad becomes congested. You literally have less capacity to remember where you put your keys or to mentally organize your tasks for tomorrow.
What makes this particularly insidious for sleep is that these same systems are involved in the cognitive processes that normally help us transition into sleep. We use our visuospatial sketchpad to engage in calming mental imagery. We use our phonological loop to follow progressive muscle relaxation scripts or to mentally repeat a soothing phrase. When anxiety has colonized these systems, even our go-to sleep strategies become difficult to execute.
Research from the University of Miami highlights that with anxiety, racing thoughts related to constant worries become the norm. These aren’t just emotionally distressing—they represent actual cognitive tasks consuming working memory resources. Each worry is a problem your brain is actively trying to solve. It’s using precious cognitive capacity that should be available for rest and recovery.
The Sleep Deprivation Amplifier Effect
Here’s where the cycle becomes truly vicious. Studies of sleep deprivation and working memory show that losing sleep directly impairs the very systems that anxiety is already compromising. When you’re sleep-deprived, your central executive—the master controller that allocates resources and maintains focus—becomes significantly less efficient.
Consider the findings from research on acute stress and working memory: anxiety mediates the effect of stress on working memory performance, but only when cortisol levels are elevated. Sleep deprivation raises cortisol. So now you have anxiety consuming working memory resources and sleep deprivation making those resources even more scarce. On top of that, elevated stress hormones amplify the whole mess.
Dr. Andrea Goldstein-Piekarski, assistant professor of psychiatry at Stanford, describes the relationship as bidirectional: “It’s becoming increasingly clear that sleep and mood have a bidirectional relationship.” But it goes deeper than mood—the cognitive consequences create their own feedback loop. Poor working memory makes it harder to employ the cognitive strategies needed to manage anxiety. This worsens sleep, which further degrades working memory.
Research examining this cascade found that worse sleep quality correlated significantly with increased depression, anxiety, and distress symptoms. These mental health symptoms then specifically correlated with longer sleep latency (time to fall asleep) and more sleep disturbances. They also correlated with increased daytime dysfunction. Each element reinforces the others.
The Mechanism: Why Simply “Relaxing” Doesn’t Work
When well-meaning friends tell you to “just relax” or “stop worrying so much,” they’re missing the fundamental mechanism. The attentional control account of working memory capacity suggests that individual differences in working memory depend on three key abilities. These are: your ability to select relevant information, resist distraction, and maintain access to relevant information outside immediate awareness. This is particularly true for performance on complex tasks.
Anxiety systematically undermines all three of these abilities. Worry is attentionally demanding. It acts as a continuous secondary task during any cognitive performance, including the cognitive task of falling asleep. Research on attentional control theory proposes that anxiety interferes specifically with the ability to inhibit irrelevant stimuli and responses.
This explains why counting sheep doesn’t work when you’re anxious—you’re not just trying to focus on sheep, you’re trying to prevent your attention from being captured by the 47 other things your mind wants to worry about. The sheep-counting is attempting to occupy working memory capacity that anxiety has already commandeered.
Neuroimaging studies reveal decreased processing efficiency in the dorsolateral prefrontal cortex and ventrolateral prefrontal cortex in anxious individuals during working memory tasks. These brain regions are crucial for executive control. They help direct attention away from worry and toward sleep-conducive thoughts.
Additionally, recent research on generalized anxiety disorder and insomnia emphasizes their shared neurobiological dysfunctions: heightened hypothalamic-pituitary-adrenal axis activity, increased amygdala reactivity, reduced prefrontal cortical control, and deficits in the GABAergic system. These aren’t just anxiety problems or just sleep problems—they’re cognitive control problems manifesting in both domains.
Breaking the Cycle: A Different Approach
Understanding that anxiety and sleep problems stem from shared cognitive resource limitations suggests a different intervention strategy than treating them as separate issues. Rather than asking “How do I reduce anxiety?” or “How do I sleep better?”, we might ask “How do I reduce the cognitive load that’s overwhelming my working memory system?”
According to recent findings, working memory training shows promise as an intervention to reduce anxiety symptoms, with a small but significant effect (Hedge’s g = -0.392). This makes sense—if we can increase the overall capacity or efficiency of working memory, there’s more room for both necessary cognitive tasks and for the worry that anxiety produces, potentially reducing the overwhelming sense that creates hyperarousal.
Cognitive behavioral therapy for insomnia (CBT-I) works partly through this mechanism. Dr. Goldstein-Piekarski explains: “We work on decoupling the connection between the bed and arousing feelings. When someone has insomnia, they are so aroused and anxious, it prevents them from being able to fall asleep.” This decoupling is fundamentally about reducing the cognitive load associated with bedtime—making the bed a simpler cognitive context rather than a trigger for working memory to spin up anxiety-related processing.
But here’s what’s often missed: if you’re still carrying the day’s cognitive demands into the evening—unfinished task lists, unresolved interpersonal issues, decisions that need to be made—your working memory will continue processing these even as you try to sleep. It’s not enough to practice relaxation; you need to systematically reduce what your brain has on its plate.
This might mean:
- Externalizing working memory demands: Writing things down isn’t just organization—it’s literally offloading cognitive tasks from your working memory. That mental task list consuming your phonological loop? Put it on paper where it can’t compete for cognitive resources.
- Time-boxing worry: Designate a specific time earlier in the day to actively worry and problem-solve. This sounds counterintuitive, but research suggests that giving worry a specific slot can reduce its intrusion during sleep hours. You’re not eliminating worry; you’re controlling when it accesses your working memory.
- Reducing decision fatigue before bed: Each unmade decision occupies working memory space. Make routine decisions (what to wear tomorrow, what to have for breakfast) in advance. Clear the cognitive deck.
- Strategic information consumption: Watching news or scrolling social media before bed isn’t just emotionally activating—it’s loading new information into working memory that your brain will then try to process overnight.
The 2025 mental health awareness campaigns from the World Health Organization underscore that depression and anxiety increase the risk of chronic illnesses, but they also highlight that quality sleep supports both mental and physical well-being. It’s not one-directional—these elements form an interconnected system.
Save This Article for Later – Get the PDF Now
The Bigger Picture: What Research Tells Us
Looking at the broader research landscape, several patterns emerge that should inform how we think about the anxiety-memory-sleep connection:
Studies examining the relationship between sleep, mental health, and working memory in students found that despite worse mental health and sleep during academic periods, working memory actually improved—likely because the increased cognitive demands forced more efficient resource allocation. This suggests that working memory capacity isn’t fixed; it responds to how we manage cognitive load.
However, the same research found that anxiety, depression, and distress scores correlated significantly with worse sleep quality across all domains—sleep quality, longer latency, more disturbances, and increased daytime dysfunction. The implication? We can’t just accept poor sleep as the price of managing anxiety; we need to address the cognitive mechanisms underlying both.
Research on state versus trait anxiety shows that both forms negatively correlate with working memory performance across task paradigms and content types. Whether your anxiety is situational or chronic, it’s compromising your cognitive capacity. But there’s also evidence that even in non-clinical populations, everyday stress and anxiety impact cognition more than previously recognized.
This matters because many people dismiss their anxiety as “normal stress” and their memory problems as “just getting older” without recognizing that these might be two manifestations of the same cognitive resource competition—and that sleep is both a victim and a potential solution.
What Does This Mean for You?
If you’re lying awake at night, mind racing, struggling to remember where you left your phone during the day, you’re experiencing the very real consequences of working memory competition. This isn’t weakness or a character flaw—it’s a predictable outcome of how your brain’s cognitive systems function when anxiety consumes resources meant for other purposes.
The path forward isn’t just about anxiety management or sleep hygiene in isolation. It’s about recognizing that your working memory is a limited, precious resource, and that anxiety, daily cognitive demands, and sleep requirements are all competing for the same pool of capacity.
What strategies have helped you manage the intersection of anxiety, memory, and sleep? Have you found ways to reduce your cognitive load before bedtime? I’d be curious to hear what approaches have (or haven’t) worked for you in the comments below.
FAQ
Q: What is working memory?
A: Working memory is a limited-capacity system that temporarily holds and manipulates information needed for complex cognitive tasks. Think of it as your brain’s active workspace—it’s where you hold a phone number while dialing it, follow a set of directions, or mentally calculate a tip. It’s distinct from long-term memory and includes multiple components: the phonological loop (verbal information), visuospatial sketchpad (visual and spatial information), central executive (control and coordination), and episodic buffer (integrating information across systems).
Q: What is the phonological loop?
A: The phonological loop is one component of working memory that processes and temporarily stores verbal and acoustic information through silent rehearsal. When you repeat a phone number to yourself to remember it, or when you’re reading this sentence and holding earlier words in mind to understand the complete thought, you’re using your phonological loop. It has limited capacity—typically holding information for only 1-2 seconds unless actively refreshed through rehearsal.
Q: What is the visuospatial sketchpad?
A: The visuospatial sketchpad is the working memory component that handles visual and spatial information. When you try to remember what someone looks like, imagine how furniture would fit in a room, or recall where you parked your car, you’re engaging your visuospatial sketchpad. Like the phonological loop, it has limited capacity and can be overwhelmed when multiple visual or spatial tasks compete for attention—such as when anxiety produces intrusive imagery alongside the spatial memory demands of daily life.
Q: What is the central executive in working memory?
A: The central executive is the control system of working memory, acting as an attention director that coordinates the phonological loop and visuospatial sketchpad, switches between tasks, and inhibits irrelevant information. Think of it as the manager deciding where to allocate your limited cognitive resources. When anxiety is high, the central executive becomes less efficient—it struggles to filter out worry-related thoughts and maintain focus on sleep-conducive mental activities.
Q: How does anxiety compete with working memory?
A: Anxiety doesn’t just reduce working memory capacity—it actively consumes it. Worry involves verbal rehearsal (using the phonological loop) and often visual imagery of feared outcomes (using the visuospatial sketchpad). When these systems are occupied with anxiety-related processing, there’s less capacity available for other cognitive tasks. Research shows this competition creates a dual-task scenario where the brain simultaneously tries to process worry and whatever else you’re attempting to do—including the cognitive processes involved in falling asleep.
Q: What does “Hedge’s g” mean in the research findings?
A: Hedge’s g is a statistical measure of effect size that tells us how large the relationship is between two variables while accounting for sample size. In the anxiety-working memory research, a Hedge’s g of -.334 means there’s a moderate, reliable negative relationship—higher anxiety consistently correlates with lower working memory performance. The negative sign indicates the inverse relationship: as one goes up, the other goes down. The magnitude (around 0.3-0.4) is considered a small to medium effect, meaning it’s meaningful but not overwhelming—anxiety explains part, but not all, of working memory differences between individuals.
Q: What is the attentional control account of working memory?
A: The attentional control account proposes that individual differences in working memory capacity—particularly on complex tasks—stem primarily from differences in the ability to control attention. This includes selecting relevant information, resisting distraction, and maintaining access to information outside immediate awareness. Anxiety compromises all three functions: it makes it harder to select what’s important (worry seems urgent even when it’s not), impairs the ability to resist distraction (worry intrudes repeatedly), and disrupts maintenance of goal-relevant information (you lose track of what you were doing).
Q: What is state anxiety versus trait anxiety?
A: State anxiety is temporary, situational anxiety—like feeling nervous before a presentation or worried about a specific upcoming event. Trait anxiety is a more stable personality characteristic—a general tendency to perceive situations as threatening and respond with anxiety. Research shows both types negatively impact working memory performance, though they may do so through slightly different mechanisms. State anxiety represents an active cognitive load happening right now, while trait anxiety may affect how cognitive resources are allocated even at baseline.
Q: What does it mean that the relationship between anxiety and sleep is bidirectional?
A: Bidirectional means influence flows in both directions: anxiety disrupts sleep, and poor sleep worsens anxiety. This creates a reinforcing cycle. Anxiety consumes working memory resources needed for the cognitive processes that facilitate sleep onset, making it harder to fall asleep. Then, sleep deprivation reduces the efficiency of the central executive and overall working memory capacity, making it harder to regulate emotions and control anxious thoughts, which increases anxiety. Each element amplifies the other rather than one simply causing the other.
Q: What is CBT-I?
A: CBT-I stands for Cognitive Behavioral Therapy for Insomnia. It’s a structured program that teaches specific behavioral and cognitive strategies to improve sleep without medication. It includes techniques like stimulus control (associating bed with sleep rather than wakefulness), sleep restriction (initially limiting time in bed to actual sleep time), relaxation training, and cognitive restructuring (changing unhelpful thoughts about sleep). Research shows it’s highly effective, particularly because it addresses the cognitive and behavioral factors maintaining insomnia rather than just treating symptoms.
Q: Why doesn’t counting sheep work when you’re anxious?
A: Counting sheep is meant to occupy your working memory with a simple, repetitive task to prevent worrying thoughts from intruding. However, when you’re anxious, your working memory is already heavily engaged in worry-related processing. The sheep-counting has to compete for attention with the anxiety, rather than replacing it. The central executive—which should be directing attention toward the sheep and away from worry—is compromised by anxiety, making it ineffective at maintaining focus on the counting task. It’s like trying to have a quiet conversation in a noisy restaurant; the background noise (anxiety) overwhelms the signal (sheep).
Q: How does sleep deprivation affect working memory differently than anxiety does?
A: While both impair working memory, they do so through different mechanisms. Sleep deprivation primarily affects the efficiency and coordination functions of the central executive—you become slower at processing information, worse at switching between tasks, and less able to filter out irrelevant information. Anxiety, in contrast, occupies working memory capacity with worry-related content. Think of sleep deprivation as slowing down your computer’s processor, while anxiety is like having too many programs running simultaneously. In practice, when you have both—which is common—they compound each other, creating more severe cognitive impairment than either alone.
Q: Can improving working memory capacity reduce anxiety?
A: Research suggests yes, to a degree. Meta-analyses of working memory training programs show a small but significant reduction in anxiety symptoms. The theory is that increasing working memory capacity means there’s more “room” for both necessary cognitive tasks and the processing demands of anxiety, reducing the sense of being overwhelmed that contributes to anxious arousal. However, working memory training isn’t a cure-all—it’s one tool among many, and its effects are modest. It works best when combined with other interventions that directly address anxiety and sleep.
Q: How does the 2025 global mental health situation relate to this research?
A: The World Health Organization’s 2025 reports reveal that over 1 billion people globally live with mental health conditions, with anxiety and depression being the most common. These conditions cost the global economy approximately $1 trillion annually, primarily through lost productivity. The recognition that anxiety and depression increase risk for chronic physical illnesses underscores the interconnected nature of mental health, cognitive function, and overall health—including sleep. The research on anxiety, working memory, and sleep adds a cognitive neuroscience perspective to these broader public health concerns, helping explain why mental health conditions have such far-reaching effects on daily functioning.
Q: What role does cortisol play in the anxiety-working memory-sleep connection?
A: Cortisol is a stress hormone that, at moderate levels, can enhance certain cognitive functions but at high levels impairs working memory and sleep. When you’re anxious, cortisol levels often rise. Sleep deprivation also elevates cortisol. Research shows that anxiety’s negative effect on working memory is mediated by cortisol—anxiety impairs working memory more severely when cortisol levels are high. This creates another reinforcing loop: anxiety raises cortisol, which impairs working memory and sleep, which raises cortisol further, which worsens both anxiety and cognitive function. Managing stress to regulate cortisol can help break this cycle.
Q: If anxiety is using my working memory, why do I still feel like I can’t stop worrying?
A: This is a common frustration that reflects how working memory actually operates. Worry isn’t stored in working memory; it’s actively generated and maintained there through rehearsal and elaboration. Your brain keeps “refreshing” the worry, cycling it through the phonological loop and generating related imagery in the visuospatial sketchpad. The central executive, which should be directing attention away from this process, is compromised by the anxiety itself. It’s like a feedback loop—worry consumes resources, which reduces your ability to stop worrying, which generates more worry. This is why interventions that change what your brain is doing (like externalization strategies or scheduled worry time) can be more effective than just trying harder to stop thinking about it.

