A new study in the Journal of Management finds that on days people have sex at home, they report being happier and more engaged in the workplace the following day.

This provocative result came from a two-week diary study of 159 married adults who were employed full-time. Participants were mostly heterosexual and age 35 on average. For each day of the study, participants completed three online surveys—one in the morning, one in the afternoon, and another in the evening.

The morning survey inquired about participants’ frequency of sexual intercourse the previous day and their current mood state, the afternoon survey looked at how satisfied and immersed they felt at work, and the evening survey asked about work-life conflict issues they experienced.

On days participants had sex, they felt happier at work the following day. Specifically, positive moods increased about 5 percent on average. Employees were more satisfied and engaged with their jobs on post-sex days as well. At the same time, on days people felt particularly stressed and pressured at work, they were less likely to have sex when they got home, which tells us that there’s a two-way relationship here: While sex might make us happier at work, bringing work home seems to interfere with our sex lives.

It’s worth noting that the researchers controlled for marital satisfaction in these analyses in order to rule out the possibility that any effects are simply due to how people felt about their relationships. I should also mention that these results held for both women and men, which suggests that any benefits of sex in terms of workplace performance aren’t limited to one gender.

So what exactly is going on here? Why does sex at home seem to benefit us at work? To find out, I spoke to the lead author of this study, Keith Leavitt, an associate professor at Oregon State University. He says it may be because sex changes us biologically. In his view, the changes in positive mood are “likely a function of both dopamine and oxytocin triggered by sexual activity.” In other words, maybe we’re just witnessing the lingering effects of sex-induced changes in neurotransmitter and hormone levels.

However, Leavitt suggests that there may be more to the story. In his ongoing research on this topic, he says he’s found that “individuals report feeling a greater sense of self-control and focus the next day following sex.” Leavitt suggests this is because sex improves the quality of our sleep and that sleep, in turn, restores our self-control abilities. This may allow us to more effectively concentrate on work the next day rather than getting sidetracked by thinking about other things—you know, like sex.

More From Tonic:

It’s also possible that what we’re seeing here is just a demonstration of the stress-relieving properties of sex. For example, a 2012 diary study published in the Journal of Social and Personal Relationships found that when couples had sex on a high-stress day, they experienced a decrease in stress the day after.

Reducing stress would obviously make us happier and more effective on the job; however, there may be benefits that extend well beyond this, including a potential improvement in the way we treat our co-workers. When we’re stressed, our bodies enter a heightened state of physiological arousal due to the “fight-or-flight” response kicking into gear. Such arousal has the potential to amplify aggressive responses when we feel provoked, something social psychologists refer to as excitation transfer. So to the extent that sex helps us to stay calm, we might actually see less aggression and more congeniality in the workplace.

Consistent with this idea, Leavitt says that in some forthcoming studies, he and his colleagues discovered that “the home sex lives of managers meaningfully predict how well they treat their subordinates the next day.” In other words, let’s hope our bosses are having a lot of sex, too.

With all of that said, there are a few caveats to this study. First, the researchers only asked about experiences with sexual intercourse. As a result, it’s not clear whether the effects here are specific to intercourse, or if other forms of sexual activity—like oral sex and mutual masturbation—might yield similar benefits. However, Leavitt points to neurobiological research finding that intercourse triggers stronger hormonal effects than other forms of sexual contact, which he cites as a reason to believe that intercourse might be especially beneficial when looking at workplace outcomes.

Second, the researchers did not assess quality of sex. They asked people how many orgasms they had and reported that taking that into account didn’t change the results; however, orgasmic frequency isn’t quite the same as sexual enjoyment. For example, it’s possible to orgasm during two different sexual encounters, but to enjoy one a lot more than the other. As a result, it’d be useful for future research to explore the effects of both quantity and quality of sex.

With all of that said, you don’t want to try and make yourself more productive at work by forcing yourself to have more sex. Studies have found that when people force themselves to have sex, it actually decreases happiness—and that defeats the purpose.

In other words, don’t make yourself have sex if you don’t really want it. Instead, you’d do well to take a cue from Leavitt and focus on removing barriers to physical intimacy like responding to late night work calls and emails. “Setting firm boundaries between work and home when you can is a great policy,” he says. “This leaves more time and mental bandwidth for everything else of consequence, which would include sex.”

Leavitt also says that if you’re a manager, try to model a norm of work-life balance. This means not sending midnight emails and expecting a response. “The momentary increase in productivity you might get by corresponding over email late in the evening is likely going to be offset by the fact that the home-life cost of that disruption will be carried back to work the next day.”

Justin Lehmiller is the director of the Social Psychology Program at Ball State University, a faculty affiliate of The Kinsey Institute, and author of the blog Sex and Psychology. Follow him on Twitter @JustinLehmiller__.