People who want to lose weight are more likely to spend time with others whose body mass is similar to their own, says a study published last month in the journal Obesity. But they might have more success dropping pounds by including thinner people in their social networks, as well.

That’s what researchers found when they asked more than 9,000 adults ages 18 to 65 about their weight goals and their closest companions. However, they say, their results are not meant to suggest that people ditch their current pals—or make new ones based on weight alone. In fact, they hope that their findings will encourage people to be more confident in themselves, not more exclusive in their friend groups.

For the study, participants were asked whether or not they wanted to lose weight, and to list the four people with whom they spent the most free time or interacted with the most via phone, email, texting, or social media. They were also asked to describe the physical build of those four people in relation to their own. Then the researchers tracked how their social networks, and their body masses, changed over the course of a year.

They found that people who wanted to lose weight often spent more time with people who were also carrying extra pounds. But when participants did spend more time with thinner people over the course of the year, researchers noticed something: Those people were more successful at losing weight.

RELATED: 16 Ways to Lose Weight Fast

Having fewer than 100 interactions with a more slender person was associated with only a fraction of a pound lost. But as people spent more time together—and had hundreds and even thousands of interactions—the effect become more substantial.

Because the study didn’t track what these people were doing together, the authors can’t say exactly why that’s the case. “They might be going out to eat; they might be going to the gym; they might be doing something totally unrelated,” says lead author Matthew Andersson, PhD, an assistant professor of sociology at Baylor University in Waco, Texas.

Andersson, who conducted the research while at Yale University, says there are many theories as to why weight loss seems to be contagious within social networks. (His co-author, Nicholas Christakis, MD, PhD, the co-director of the Yale Institute for Network Science, has studied how other healthy and unhealthy habits can spread in similar ways.)

RELATED: 57 Ways to Lose Weight Forever, According to Science

These mechanisms “may include shared activity habits, shared eating habits, shared recreational or leisure activities, or shared norms, expectations, or preferences that others may have for one’s behavior or appearance,” he says. In other words, it may be easier for people to lose weight if they’re spending time with someone who views exercise or healthy eating as a priority—like a personal trainer or a health-conscious friend.

But at the same time, Andersson points out, there are lots of other influences at play. “Friendship ties to thin folks aren’t the be-all and end-all,” he stresses.   

“We don’t want to send the message that individuals should be superficial about choosing whom to spend time with socially,” he says. Instead, “folks should take time to remember that even a seemingly personal goal like losing weight actually has deeply social factors influencing its success.”

RELATED: Why Having a Best Friend Is Good for Your Health

Andersson encourages everyone to cultivate ties with a variety of people regardless of body type, and to draw on different individuals at different times in their lives in order to meet their personal health goals. And he hopes that, by raising awareness about these potential influences on weight loss, his research can empower people to be more confident and accepting in all social situations, not less.

“Individuals probably should simply have heightened awareness of how their friends may be influencing them,” he says, “and then make friendship decisions from there.”