You’re in the middle of a big race when, out of nowhere, your stomach starts to churn. Instead of focusing on crossing the finish line with a new PR, you’re now worried about just making it there without puking or pooping—or both. And yet, you’re determined to finish this thing. So what should you do?

Most runners have been plagued with nausea, vomiting, loose bowel movements, or diarrhea at some point or another. In fact, one study found that more than 60 percent of distance runners have had to stop midrun to poop. This is often referred to as “runner’s stomach,” a kind of catch-all term that represents the many ways your stomach can attempt to sabotage you during a run. You may also hear this referred to as the “runner’s trots” thanks to the short, quick steps you’re forced to take when suffering.

Fortunately, there are things you can do to cope with the discomfort. Here’s why your stomach might start to hurt while you’re racing and how to soothe it ASAP so you can get back on track.

What Causes Runner’s Stomach and Runner’s Trots?

All that bouncing up and down can actually jostle your organs and push food through your digestive tract faster, explains Peyton Berookim, M.D., F.A.C.G., director of the Gastroenterology Institute of Southern California. At the same time, some of the blood that normally flows to your intestines is being diverted away toward your leg muscles. All of these factors can mess with your digestion and leave you feeling queasy or like you need to find a bathroom right away.

Hormones can also play a role. High-endurance exercise like running signals the release of the stress hormone cortisol, which can contribute to that sensation of having to go, Berookim says. And the anxiety and pressure that can sometimes come with racing only make things worse.

According to both Berookim and Amy Goodson, M.S., R.D., a board certified specialist in sports dietetics, the wrong foods and drinks can also add fuel to the gastrointestinal fire. High-fiber foods, high-fat foods, spicy foods, foods containing fructose or sugar alcohols, and caffeine can all turn race day stomach problems into an even bigger deal. So can eating anything within two hours of running.

How to Settle Your Stomach During a Race

If you have to battle runner’s trots during a training run, it’s not the end of the world. But when that gurgle in your belly hits midrace, there’s a lot more to lose (read: a new PR). Prevention is really the best medicine in this case (more on that below!), but there are a few things you can do while pounding the pavement to help ease your discomfort.

1. Slow down. Fast running is more likely to mess with your stomach than a gentle jog. “Slowing your pace down allows blood flow to redistribute to your GI tract, and it might help you feel better,” explains Goodson.

2. Sip some water. It might seem counterintuitive, but dehydration can actually lead to diarrhea, Berookim says. Try to get your hands on some cold water instead of H20 that’s been sitting out in the sun for a while. “Warm liquids can speed food through the digestive tract,” Berookim explains. And that could make your stomach problems worse.

3. Eat something bland. Sometimes nausea can be the result of an empty stomach. If you didn’t fuel up before the race or feel a combo of hunger and nausea, try eating a handful of plain crackers or a bland granola bar, Goodson recommends.

4. Stop and go to the bathroom. That urge to poop probably isn’t going to disappear, and there’s a good chance it’ll get stronger as you keep running. “If you have to go to the bathroom, probably just stop and go,” Goodson says. Sure, it’ll slow you down by a minute or two. But if it helps you feel better, you might be able to make it up and stay on track.

[Build a killer midsection in the kitchen for effortless miles on the road with Eat for Abs!]

If you’re still uncomfortable postrace, rehydrate with unsweetened iced ginger or chamomile tea. Both contain compounds that can help reduce nausea, Goodson says. On the food front, keep it bland and basic. Plain crackers or toast can replenish your carbs and get something in your stomach without irritating it more. And bananas act as a binder to help stop diarrhea while serving up lost electrolytes like potassium, says Goodson.

When to Stop Running (And What to Do Next Time)

Even if you’re dead set on making it to the end, it’s important to listen to your body—and know when you’re better off calling it quits. Dizziness, lightheadedness, a headache, or actual vomiting are all signs that you should stop running, rest, and hydrate, Berookim says.

As for future races? Bill Rodgers once quipped, “More marathons are won or lost in the porta-toilets than at the dinner table.” And he wasn’t kidding. Rare is the distance runner who hasn’t had some stomach or bowel distress during a race. And even though marathons aren’t often televised, there have been several famous cases of on-camera elites vomiting or ducking off course en route (see: Shalane, Boston, 2018). While there’s no surefire way to prevent runner’s stomach, these tactics can help.

1. Stick with familiar foods. Your prerace dinner or breakfast isn’t the time to try something new. “Knowing that you naturally will be more jittery the morning of the race, practice your prerun meal just like you practice your run,” Goodson says. “Try a few breakfasts on long run days and see what works best.” Once you find what works, stick to it.

2. Don’t eat within two hours of racing. Having your prerace breakfast early means you won’t have still food in your stomach when you actually start running. Give your body enough time to digest before the running starts, even if that means eating something and then going back to sleep before early morning races.

3. Avoid potential irritants. High-fiber, high-fat, high-fructose, and spicy foods, as well as sugar alcohols or sugary drinks can all send you running to the bathroom, so start steering clear the night before your race, Berookim recommends. If caffeine tends to cause a problem, try to go without your morning coffee.

4. Check your sports supplements. Many gels, bars, and sports drinks contain fructose, a type of sugar that can cause gas and bloating, so avoid trying new ones on race day.

5. Save pain relievers for after the race. NSAIDs such as ibuprofen or naproxen can irritate your stomach.

6. Stay hydrated. Practice drinking in training to improve your comfort with fluids while running. In the days leading up to the race, make sure to take in lots of fluids to avoid dehydration.

[Related: How to Make Yourself Poop]

Headshot of Marygrace Taylor
Marygrace Taylor
Marygrace Taylor is a health and wellness writer for Prevention, Parade, Women’s Health, Redbook, and others. She’s also the co-author of Prevention’s Eat Clean, Stay Lean: The Diet and Prevention’s Mediterranean Kitchen. Visit her at marygracetaylor.com.