Even if you don’t consider yourself a daydreamer, you probably spend a lot of time in a state of mental wandering ― it’s natural for your mind to drift away from the present moment when you’re in the shower, walking to work or doing the dishes.

In recent years, scientists have been paying a lot more attention to mind-wandering, an activity that takes up as much as 50 percent of our waking hours. Psychologists previously tended to view mind-wandering as largely useless, but an emerging body of research suggests that it is a natural and healthy part of our mental lives.

Researchers from the University of British Columbia and the University of California, Berkeley conducted a review of over 200 studies to highlight the relationship between mind-wandering ― often defined in psychological literature as “task-unrelated thought,” or TUT ― and the thinking processes involved in creativity and some mental illnesses, including attention deficit hyperactivity disorder, anxiety and depression.

“Sometimes the mind moves freely from one idea to another, but at other times it keeps coming back to the same idea, drawn by some worry or emotion,” Dr. Kalina Christoff, lead study author and principal investigator of the Cognitive Neuroscience of Thought Laboratory at UBC, said in a statement.

“Understanding what makes thought free and what makes it constrained is crucial because it can help us understand how thoughts move in the minds of those diagnosed with mental illness,” she said.

The Role Of A Wandering Mind

Traditionally, mind-wandering has been defined as thinking that arises spontaneously, without relating to any sort of task or external input. But this definition is only a starting point: Without external focus, the researchers explain, the mind moves from one thought to another ― jumping between memories, imaginings, plans and goals.

This default “spontaneous mode” can be hemmed in in two ways: A person can deliberately turn their attention to a task, or, in the case of someone with a mental health issue, focus can happen because thoughts have gotten stuck on a persistent worry or pulled away by an environmental distraction.

On a neurological level, the brain’s default mode network ― a broad network that engages many different cognitive processes and regions on the internal surface of the brain ― activates when our minds wander. In contrast, when we focus our attention on a goal, plan or environmental stimulus, the part of the brain devoted to external attention is more active.

Specifically, the researchers pinpointed the memory and imaginative centers within the default mode network as being largely responsible for the variety of our spontaneous thoughts.

“You’re jumping around from one thing to another,” Zachary Irving, a postdoctoral scholar at the University of California, Berkeley and study co-author who has ADHD, told The Huffington Post. “We think that’s the default state of these memory and imaginative structures.”

A Creative Mind Is A Wandering Mind

Creative thinking can be an extension of ordinary mind-wandering, the researchers explained, and a growing body of research has linked daydreaming with creativity. In highly creative people, psychologists have observed a tendency toward a variation on mind-wandering known as “positive-constructive daydreaming,” in which has also been associated with self-awareness, goal-oriented thinking and increased compassion.

The free play of thoughts that occurs in mind-wandering may enable us to think more flexibly and draw more liberally upon our vast internal reservoir of memories, feelings and images in order to create new and unusual connections.

“Mind-wandering in the sense of the mind moving freely from one idea to another has huge benefits in terms of arriving at new ideas,” Christoff said. “It’s by virtue of free movement that we generate new ideas, and that’s where creativity lies.”

Nature Reviews Neuroscience

This chart presents a visualization of different types of thinking, including variations of spontaneous thought.

What Mind-Wandering Can Tell Us About Mental Illness

This type of mental activity can provide an important window into the thinking patterns that underly psychological disorders involving alterations in spontaneous thought.

The mind of someone with ADHD, for example, wanders more widely and frequently than that of an average individual. In someone with anxiety and depression, the mind has an unusually strong tendency to get stuck on a particular worry or negative thought.

“Disorders like ADHD and anxiety and depression aren’t totally disconnected from what normally goes on in the mind,” Irving said. “There’s this ordinary ebb and flow of thoughts, where you’re moving from mind-wandering to sticky thoughts to goal-directed thoughts. ... We think of these disorders as exaggerated versions of those sorts of ordinary thoughts.”

So despite what your elementary school teachers may have told you, it’s perfectly fine to let your thoughts wander every once in a while. But if you find your mind wandering too much or getting stuck on negative thoughts, it may be time to seek help.