Getting healthy can be a daunting endeavor. It can seem impossible to get active, eat better, sleep more, stay hydrated and do the many other things your doctor says you should do, all at once.

But recent research suggests there’s a single best place to begin. According to a study published in the International Journal of Obesity, starting an exercise regimen may also inspire you to eat more healthfully.

“It’s hard to start a diet. Most people feel deprived from the get-go,” says study co-author Molly Bray, chair of the department of nutritional sciences at the University of Texas at Austin. “Instead of taking something away, you can add physical activity to your life, and the consequent changes may be significant changes in the way you eat.”

For the study, researchers recruited more than 2,500 college students who said they didn’t diet and exercised for less than 30 minutes a week. The students were put on a 15-week aerobic exercise plan that involved doing guided cardio for 30-60 minutes, three times a week. Each person was asked to fill out a diet questionnaire at the beginning and end of the study. They were told not to change their eating habits.

But many of them did anyway. About 2,000 stuck with the exercise plan, and they were more likely than those who didn’t to eat healthier without being told to, the researchers found. Many of the exercisers started eating more nutritious foods, like fruits, vegetables, lean meats, fish and nuts, and fewer fried foods, soda and snack foods. The more — and more vigorously — a person exercised, the more their diet tended to improve, the researchers found.

Longer exercise duration was associated with a decrease in preference for foods characteristic of the standard western diet, such as red meat, fried foods and snack foods. Meanwhile, high-intensity exercise was associated with an increase in preference for healthy foods. Overall, Bray says, this means “compliance with the exercise program was associated with a move toward eating healthier overall.”

The study didn’t look at why working out seemed to spur healthy eating — future studies will focus on that question, as well as what impact strength-training might have on diet, Bray says — but psychology and biology are likely both responsible.

“There’s a lot of research that positive results fuel adherence and persistence and other changes psychologically,” Bray says. “Some people may be saying, ‘Wow, look, my shorts feel looser. I’m going to work on my eating behavior.'”

But Bray says she doesn’t think conscious effort can explain the whole phenomenon. Plenty of research suggests that exercise can change brain function, and she says this rewiring may be behind the urge to eat more healthfully.

“I really do think exercise is altering neural processing in your brain. The stimulation of your brain that occurs with high-intensity exercise is what changes lots of things about your body,” Bray says, including what it wants to eat.

The effect likely doesn’t work both ways, Bray says; cleaning up your diet probably won’t make you want to hop on the treadmill. Though her study did not directly address that relationship, Bray says she does not believe that food choices can create brain changes the same way physical activity may.

Plus, people probably find it easier to start an exercise routine than a restrictive diet. “Add something to your life — what a good health message,” Bray says. “This is a gift you’re giving yourself, and other really significant health changes can occur along the way.”

Write to Jamie Ducharme at jamie.ducharme@time.com.