Most of us probably can’t get Mark Ronson and Bruno Mars’s catchy song “Uptown Funk” out of our heads after hearing it on the radio, TV commercials, and at the bar. Before we know it, our brain hits the “record” button and the catchy song plays on a mental “repeat” — for better or for worse. However, according to a recent study published in the Quarterly Journal of Experimental Psychology, the melody that’s obsessively replaying in an endless loop can be stopped by popping some bubblegum.

The inability to get these infectious songs or melodies out of our heads, also known as “earworms,” are experienced by over 99 percent of individuals. The mental “encore” of these songs are considered infectious because they spread similar to a pandemic. Songs like “Uptown Funk” or Maroon 5’s “Sugar” are deliberately designed to be contagious so they can become an auditory stickiness.

Commercial jingles or catchy songs target the brain’s “iPod” (primary auditory cortex) located in the temporal lobe, which is associated with short-term memory. This part of the brain is active when we’re actually listening to a song and is reactivated when you just imagine hearing the song. A 2005 study published in the journal Nature found even when a familiar song is played for three or five seconds and then stopped, we can still make up the missing bits. The brain is able to connect the dots.

Now, while the catchy song is processed similar to short-term memory, it has the ability to overpower the brain’s quick erasure mechanism with each repetition. In an effort to reduce earworms, Dr. Phillip Beaman, lead author of the study from the University of Reading, UK and his colleagues conducted three experiments to examine the role of articulatory motor programming — motor skills involved with speech — in experiencing an involuntary musical recollection when chewing gum. A total of 98 volunteers were played the catchy tunes “Play Hard” by David Guetta and “Payphone” by Maroon 5 in which they were exposed to these tunes while either chewing or not chewing gum.

In the first experiment, participants listened to “Play Hard” and then were asked to report any time they thought about the song as they were actively trying to suppress it from their memory and when they were told they could think about it whenever they wanted. The findings revealed chewing gum reduced the number of times the tune was consciously experienced in both music suppression and when thinking freely. Meanwhile, in experiment two, essentially the same as the first, chewing gum also had a reducing effect when participants actually heard the music in their heads.

Lastly, the researchers sought to test whether the effects of chewing gum were common to any kind of motor activity, or just specific to speech articulators. The participants were asked to either chew gum or tap with their fingers at the beat of a melody. The findings revealed motor activity (tapping) was less effective than sub-vocal actions (chewing) in reducing the effect of catchy songs.

In this case, co-opting the articulatory motor program to chew the gum impairs the involuntary recollection of an auditory image. Beaman and his colleagues come to the conclusion that motor activity does interfere with the experience of “hearing” musical recollections both voluntarily and involuntary. In other words, brain regions stimulated when we hear, remember, or imagine a tune are forced to be active when gum is chewed, which makes them less capable of involuntarily remembering a catchy song.

“At a practical level, therefore, chewing gum can be recommended as an aid to reduce unwanted musical recollections,” they wrote in the study.

Beaman’s study can also have implications that go beyond a solution to earworm. The research team notes chewing gum can aid in the reduction of not just unwanted musical recollections, but also hallucinatory experiences that are of a psychotic nature. This could be a stepping stone in developing methods of controlling invasive thoughts that fill the heads of those with psychiatric illnesses.

So the next time you can’t get a song out of your head, pop a stick of gum in your mouth.

Sources: Beaman P, Powell K, Rapley E. Want to block earworms from conscious awareness? B(u)y gum! The Quarterly Journal of Experimental Psychology. 2015.

Green AE, Kelley WM, Kraemer DJM, Macrae CN. Musical imagery: Sound of silence activates auditory cortex. Nature. 2005.