According to WebMD, compulsive tail biting in dogs can occur for a variety of reasons, including allergies, anxiety, dry skin, epileptic seizures, injury and parasites. There are also certain dog breeds that have genetic dispositions to compulsive behavior that can lead to tail biting. Low levels of the brain chemical serotonin combined with high levels of dopamine in dogs can also cause compulsive behaviors.
In order to determine if the behavior is due to a medical condition, it is important for dog owners to consult a veterinarian. Tail biting due to compulsive behavior can be minimized with chew toys, exercise and bitter-tasting sprays to discourage the biting. If compulsive tail biting is caused by an allergy or fleas, the condition can easily be treated with antihistamines and over-the-counter flea powders. Special collars can also be used to minimize the dog's access to its tail. Early diagnosis and treatment helps prevent tail biting from becoming a habitual response.
If a dog's tail-biting behavior doesn't improve with a change of environment, increased activity, medical treatment for any underlying condition, chew toys or sprays, it is a good idea for dog owners to consider treatment with anti-anxiety medications or anti-depressants that help control anxious and compulsive behaviors.