If you’re an athlete with celiac disease, a gluten-free diet is a necessity. For those with gluten sensitivity, it’s a matter of comfort. “Everybody else has to experiment” to find out how — or if — the diet benefits them, says Leslie Bonci, director of sports nutrition at the University of Pittsburgh Medical Center. And that’s okay “as long as you do it the right way,” she says. Here’s how:

It’s not just what you cut out.

“Gluten-free isn’t the most important thing; the most important thing is eating properly,” says Washington area running coach Joe Shannahan. “My advice always is: Do what your grandma told you, and eat a well-balanced diet.”

Bonci agrees. She suggests dividing your plate into thirds — one for protein, one for produce and one for “wiggle room.” If you used to load that last third with pasta, try quinoa or rice instead. If your breakfast used to be iron-fortified toast, consider getting that iron by eating such foods as gluten-free oats with prunes and nuts.

●Timing is everything.

Most athletes know that even swapping Powerade for Gatorade can destroy a stomach or fog a head accustomed to one or the other. That’s why Bonci recommends experimenting with a new diet — including a gluten-free one — at least three to four months before race day.

Athletes who don’t replace their bread and pasta with another starch such as potatoes or corn, as “Wheat Belly” author William Davis advocates, need to give their new diet extra time. For the next few weeks, many will experience withdrawal from the addictive properties of wheat as their bodies get used to burning more fuel from stored body fat, he says.

But not all experts agree that more prep time is better. Alessio Fasano, director of the Center for Celiac Research at Massachusetts General Hospital for Children, says that when the goal is to boost athletic performance at a particular event, starting the diet months before without strict oversight might risk throwing off an athlete’s balance of nutrients.

●Gluten-free isn’t guilt-free.

When it comes to calories, “it’s not a one-for-one swap out,” Bonci says. For example, gluten-free bread made with rice flour might pack twice the calories of a whole-wheat slice. Some athletes need the extra calories, but “not everybody does,” she says.

Davis encourages athletes to “go gluten-free, but don’t eat ‘gluten-free.’ ” In other words, focus on eating whole, unprocessed foods such as nuts and steamed vegetables rather than swapping your pita chip for a corn chip. “Gluten-free foods are made with rice flour, potato starch, corn starch and tapioca starch — the only starches that raise blood sugar higher than even wheat,” he says. “It’s like some cruel joke.”

●All or nothing.

You can’t just dabble if you truly want to find out whether a gluten-free diet will help you. It’s important to do your homework and work “under the supervision of knowledgeable dietitian,” Fasano says. “There are hidden sources of gluten that can, eventually, put your GI system under extra work, and therefore it defeats your purpose.”

It’s also a good idea to keep detailed notes about what you eat and drink, how you feel, how well you sleep, how you perform and how fast you recover. Because until we have more research in the area, you’re your own case study, Bonci says.

Anna Medaris Miller