Even if your sights aren’t set on running a marathon, we’ve all had those days when you slow to a walk during a three-mile jog—even though you easily breezed through a six-miler earlier in the week. It’s not that you’re suddenly that out of shape, right?

Not at all. So what gives? Why do we want to give up completely on some runs, while we feel as unbreakable as Kimmy Schmidt on others? We asked the experts to find out.

Observe Your Body

“Every runner is going to experience an off day,” says Jeff Galloway, a running coach and former U.S. Olympian. Distance runners are all too familiar with “hitting a wall”—that can’t-go-on feeling that happens on a long run. And it’s not an urban legend: Research shows it occurs when your body is depleted of glycogen stores in the liver and muscles, resulting in an abrupt feeling of fatigue and a loss of energy.Metabolic factors limiting performance in marathon runners. Rapoport BI. PLoS Computational Biology, 2010, Oct.;6(10):1553-7358. The two biggest physical culprits? Overtraining and low blood sugar, Galloway says.

To prevent burnout, the best strategy is to scale back on your training. Jason Fitzgerald, a running coach at Strength Running and a 2:39 marathoner, endorses a strategy he calls adaptation, or repeating the same training schedule two weeks in a row. It’s beneficial because it forces you to not constantly add more mileage and do tougher workouts each week, which can be overwhelming both mentally and physically.

To fix low blood sugar, eat a pre-workout carb-based snack 60 minutes before your runs, which studies show can increase performance.Pre-Exercise Nutrition: The Role of Macronutrients, Modified Starches and Supplements on Metabolism and Endurance Performance. Ormsbee, MJ, Bach, CW, Baur, DA. Nutrients. 2014 May; 6(5): 1782–1808. Another factor is inadequate hydration, Fitzgerald says. The American College of Sports Medicine recommends hydrating with 500 milliliters (about 17 ounces) of fluid two hours before you work out.American College of Sports Medicine position stand. Exercise and fluid replacement. Convertino VA, Armstrong LE, Coyle EF. Medicine and Science in Sports and Exercise, 1997, Sep.;28(1):0195-9131.

Low muscle tension—how contracted your muscles are—is also a factor, Fitzgerald says. When you have a higher muscle tension, your muscles are primed, ready to go, and feel more spring-like. But when tension is low, your muscles don’t contract as quickly—meaning you’re more likely to feel sluggish and lethargic. Improve your muscle tension by warming up for your run on a hard surface, doing a few sprints before a run, or taking an ice bath the night before your workout.

Other factors like poor sleep and humid weather can make your usual four-mile run feel like a torturous 10-miler, Fitzgerald adds. “If you’re not getting enough sleep, you won’t recover properly or adapt to the hard workouts that you build up to,” Fitzgerald says. (Try these tips to sleep better tonight.) He also suggests checking in with yourself to ensure you’re fully recovered from your previous workouts, and asking yourself if you are patterning your workouts and runs appropriately.

Train Your Brain

Your mind plays almost as crucial a role in your runs as your physical state. Studies show that mental fatigue impairs intermittent running performance, causing runners to have a higher rate of perceived exertion (RPE).Mental Fatigue Impairs Intermittent Running Performance. Smith MR, Marcora SM, Coutts AJ. Medicine and Science in Sports and Exercise. 2015 Aug;47(8):1682-90. Galloway, who wrote Mental Training for Runners: How to Stay Motivated, explains: “We rely on the subconscious brain to do most of what we do, but if we allow it to govern our running, which it can do and often does, once the stress builds up from all sources, the brain will secrete anxiety and negative hormones, making your run a bad one.“

The good news: By having a mental training program, you can turn that around. Follow these six tips to build up your mental strength.

1. Think about something specific.

Galloway suggests focusing on the next part of your run or a fun plan you have for the upcoming weekend. “When you think of something specific, you shift out of the subconscious into the conscious, where negative hormones aren’t being produced,” Galloway explains. “Then you can start producing endorphins—a.k.a. your personal empowerment circuit.”

2. Find your “magic words”.

Associate a mantra (or “magic phrase”) with positive past experiences that will allow you to pull the strength from those successes again during a bad run. “Say the words over and over again to activate the frontal lobe of your brain, which shuts off the negative thoughts from your subconscious,” Galloway suggests. (Try something like “You can do it,“ “I got this,“ or one of these inspiring fitness mantras.)

3. Use your imagination.

This sounds wacky, but bear with us: Imagine throwing a giant rubber band around a runner ahead of you, and pretend they’re pulling you along, Galloway suggests. You might laugh at yourself, but by then you’ll be a half-mile down the road—and feeling a lot more positive.

4. Push through.

We know battling your brain’s negativity can be difficult. And while some runners may quit early, retiring to their couch and Netflix, Fitzgerald prescribes a bit of tough love. “If a runner is having a bad day because they didn’t get enough sleep, missed their morning coffee, are stressed, or it’s hot out, I suggest pushing through it when possible,” he says. “Any race you’re going to run is probably not going to go perfectly, and every run is not going to feel great. I think there’s a lot of value in a little bit of suffering.”

5. Set a goal.

To stay motivated, Fitzgerald recommends signing up for a race or having a mileage goal in mind. “If you don’t have a goal, skipping out on the last half of a run won’t have a significant impact on your training,” he explains. “Registering for a race and committing to a schedule is the best way to get and stay focused.”

6. Change up the view.

Fitzgerald mixes up his own routine by going trail running. The terrain change and new surroundings offer a mental benefit, which translates to a better run. Experiment with new settings yourself.

The Takeaway

Above all, runners should anticipate that not every run will produce the coveted runner’s high, and maybe you won’t be 100-percent mentally present at every race you run. But by sticking it out or using one of the mental training techniques above, you can turn a bad run into a good one. “Even when the pace of the run is slow, working yourself through what could have been a bad run and having it turn out decent is very empowering,” Galloway says.

Of course, if conditions are unreasonable—say, you’re at risk for heat stroke or you feel like you’re going to throw up—Fitzgerald recommends modifying your workout. “Maybe you cut 10 to 25 percent of the distance or adjust your pace expectations,” he explains. “If you’re not able to do a plan B or even a plan C of the workout that was originally scheduled, then bag it, take a recovery day, and try again tomorrow.”