Researchers at Harvard’s Nurses’ Health Study exploring conflicting findings on whether pet ownership is good for our mental health have found that having — and loving — a dog (sorry, cat people) is associated with lower symptoms of depression and anxiety.

We used several different measures for depression and for anxiety and found overall that there is an inverse association between pet attachment and negative mental health outcomes. That means the more attached you are to your pet, the lower your risk of depression and anxiety.

The effect was particularly strong among women who had a history of sexual or physical abuse in childhood, who made up the majority of our study population.

I think those findings were mostly driven by dogs, because the majority of the pets owned in the study were dogs — it was about two-thirds dogs and one-third cats. The association was similar to what we found when restricting the analysis just to dogs, but not as strong.

With cats, there doesn’t seem to be an association between pet attachment and mental health outcomes. There was a smaller number of respondents though, so we cannot rule out that we don’t see anything because there were too few cats in the survey.

Many studies have been done on the effects of pet ownership, but the premise of this study is that it may matter more how much you are attached to the pet than if you simply own a pet. Many people have pets, but not every owner is attached to their pet.

Plenty of people don’t enjoy having to walk their dogs in the morning because the dog is the beloved pet of their child, for example. So the goal was to sort out whether attachment is the more important variable that links pets to health outcomes in humans, and then to study mechanisms.