Although many people think dogs hump things because of sexual hormones, this is not always the case, indeed neutered male dogs, and female dogs alike, will hump things. Dogs will hump other dogs, people's legs, even stuffed toys, but why do they do this, and how to get them to stop?
Humping is most commonly observed in intact male dogs. It is also fair to say that some dogs do masturbate even if they are fixed. This is more common in dogs that were neutered after the age of one. These dogs may even ejaculate but there will be no sperm.
In some cases humping is a sign of a dog asserting a dominant role. This would be suspected when the dog is humping another pet, a child, or even a person's leg, or toy. A dog who is trying to assert its dominance in the family may also growl when food, or toy, is taken away away, and may drag its owner on walks.
In wild dogs returning pack members often hump those who stayed at the den as a way of bonding and reminded others of the pack order. It actually keeps bonds within the pack strong.
Social Anxiety Humping
It is also thought that some dogs hump because of social anxiety, the behavior offering them some mental relief. This might be observed when a dog is anxious or stressed, this behavior which is natural comes forth to relieve stress when a dog is faced with an unnatural situation, when a new person visits, when a new dog visits, or even when a new sofa is added to the house.
Some dogs who were not properly socialized as pups may do this as they are not familiar with proper meeting and greeting techniques with other dogs.
Attention Getting Humping
At some point dogs might learn that humping gets them attention. Dogs love attention even if it is not always good. They enjoy getting a reaction out of their owner. As such if a dog humps and is “rewarded” by being yelled at, or laughed at, or whatever, it learns to remember the commotion it caused by doing the behavior and as such does the behavior from time to time to elicit the same response.
How to get a Dog to Stop Humping Things?
If your dog is not neutered the first step to change this behavior would be to neuter it. Training and proper mental stimulation can also help relieve problems as related to dominance and anxiety.
Distracting a dog who is humping something can also work, get the dog to do something such as “sit” for a few seconds and give it a treat reward. By encouraging, and rewarding, the behavior you do want, the dog may forget the behavior you do not want. If it is humping particularly toys, remove them. Discourage a dog from humping your leg by getting up and walking away (ignoring the dog).
In some cases you just have to realize this is normal dog behavior, but if it seems too much you may take your dog to the veterinarian to have his, or her, hormone level checked.