If you’re looking for a way to push yourself further when you work out, it may be time to give competition a try. At least that’s what a 2016 study of nearly 800 students at the University of Pennsylvania suggests. According to the study published in the journal Preventive Medicine Reports, there’s a major difference in how much a person works out when they’re engaged in competition.

The study followed participants through an 11-week exercise program consisting of running, spinning, Pilates, yoga and weightlifting classes. Each person was either assigned to a group or to work out alone. Either competitive or supportive dynamics were introduced. The competitive group could track other team members’ progress but were not allowed to interact with one another. The supportive group was able to chat with and encourage team members and could go to classes together. The solo participants either worked out alone with no social network or had access only to how they were doing compared to others.

The results showed that people in the competitive group went to 90% more fitness classes than the others. What you may find equally surprising is that the people in the supportive group not only exercised less than the competitive group, but even less than those who exercised alone.

This is not the only study to show how competition can motivate you to exercise more or perform better. In another study at Arizona State University, subjects in a competitive group situation were able to lift 11% more weight in a weightlifting test than if they did it alone.

Similarly, a study at the University of California Berkeley asked subjects to ride a stationary bike at high intensity until exhaustion when they were both in competition with an equally fit person and when they were alone. The subjects lasted 20% longer at the same intensity when they were competing against someone than when they were riding solo.

So whether you’re motivated by the person you always see in your kickboxing class, you want to beat your friend when you run your next 10K or you want to compete against total strangers on social media or a fitness app, you’ll likely find that adding some competitive energy can spur your determination to move more or perform better. You’ll have a goal to strive for and a reason to go the distance. In the end, that’s certainly a win-win situation.