A new study says eating dairy close to bedtime could result in more nightmares.

Researchers in Canada say they have found a link between lactose intolerance and a higher likelihood of experiencing bad dreams. The takeaway: consider avoiding Gouda for a good night’s sleep.

The researchers believe that the distress dairy can cause to the stomach of some people can disrupt sleep, inducing more nightmares.

“The results we obtained confirmed our hypothesis that lactose intolerance is indeed predictive of disturbed dreaming and nightmares,” study co-author Russ Powell, a psychologist and professor emeritus at MacEwan University in Edmonton, Alberta, said to Gizmodo.

CLICK HERE TO GET THE DALLAS EXPRESS APP

This is not the first time dairy products, like cheese, have been linked to poor sleep.

The same team behind the latest study previously published a survey that found around one in five participants reported experiencing odd dreams, which they attributed to consuming certain foods or eating late at night. Many of the participants specifically pointed to dairy as the culprit behind their bizarre dreams.

Over 1,000 college students were surveyed for the latest research. Roughly 40% of participants reported that certain foods or late-night snacking affected their sleep, with 25% linking their diet to poor sleep. While only 5.5% of those surveyed this time around blamed foods for affecting their dreams, dairy was among the more common foods singled out.

The researchers also say that people with self-reported lactose intolerance were linked to more severe nightmares and poorer sleep.

“It may be that GI distress, in comparison to other types of physical distress, has a particularly strong impact upon sleeping and dreaming. Menstrual cramping, for example, has also been shown to increase the likelihood of disturbed dreaming,” Powell explained.

He also suspects that, because GI distress can be driven by ingesting poison, nightmares resulting from dairy might be a mechanism the body uses to alert itself in case of a medical emergency.