Must. Have. Chocolate. When food cravings hit, it’s easy to feel like a slave. That’s because cravings have their root in physiology. Trouble is, scientists can’t agree exactly where those roots are. The one thing most do agree on is that cravings are generally not your body pleading for a nutrient it needs, as we like to tell ourselves (“My body must really need the sugar and refined flours in this cupcake!”).

More likely, the cravings are a result of the complex mix of some of the following theories, each of which has scientific backing:

  • Your brain is looking to recreate past feel-good experiences, such as the release of dopamine that a sugar-binge triggers.
  • Hormone imbalances and conditions such as chronic stress may lead to more cravings.
  • The microbiota in your gut are clamoring for specific fuel they need to thrive. For example, some microbes grow best from fat; others from sugars. The downside: These aren’t always microbes you want to encourage.
  • Your circadian rhythm causes you to seek out sweet, starchy and salty foods in the evenings, usually peaking around 8 p.m. and continuing until around midnight.

Regardless of why you’re craving a certain food, it’s key to have tools to combat the urge, at least if it’s an unhealthy one. Here are research-based methods for squelching cravings—experiment with them until you find ones that work for you.

Fire Up Your Imagination

It might seem counterintuitive, but multiple studies show that vividly imagining yourself eating a food can diminish a craving for it and cause you to eat less if you do indulge. Actually, actively imagining any sensory experience—such as the smell of the ocean or the feel of raindrops on your skin—can lessen a craving. Or try looking at a lot of pictures of the food you crave. A study in the Journal of Consumer Psychology found that the first few pictures will whet your appetite, but the more pictures you look at, the more your craving wanes.

Distract Yourself

A study in the journal Appetite discovered that just three minutes of playing Tetris reduced participants’ cravings for not just food but also alcohol and cigarettes by up to 24 percent. Exercise is also a proven crave-squashing method.

Examine Your Diet

Incorporate protein into every meal or snack; people low on protein tend to experience more cravings. Also be sure to eat a wide variety of healthy foods—a narrow diet is associated with increased cravings.

Go to Bed

Remember that circadian rhythm? It can’t control you if you’re asleep.