Pets should not share a bed with their owner for a number of reasons. The feet of all pets are carriers of anything they walk on outdoors, and unless they are fresh out of a bath, feet will bring extremely undesirable elements to your cozy bed. Potentially, there are a host of microscopic elements that may cause illness. Toxoplasmosis for example, in the event a pet has walked into a kitty poop that is infected with that microbe.
Most of our pets are dogs and cats, and it seems appropriate to assume exotic pets would not be welcome in anyone's bed for obvious reasons. From licking to investigate, to eating scraps of something that smells good to them, dogs and cats tend to carry various disease producing microbes, and parasites in their system. This of course along with an assortment of leftover dirt from tires, and footsteps that have been who knows where on their feet or fur. Fur, although licked in a superficial cleaning process, has a quality that makes it protective for the animal, and also a magnet for various life forms, including fleas and ticks. Animal fur can also carry chemical elements from outdoor plants that are irritants, or even cause allergenic reactions such as Poison Oak.
In addition to the unseemly bugs and dirt, there is a psychological challenge. Dogs behave according to their genetics, and they tend to follow a leader, an alpha dog, resembling the behavior of a wolf pack. If you allow them to be an equal in any way, especially by letting them sleep with you, it a signal you are part of the pack, and they may respond by feeling the need to become the alpha. This will cause them to do more what they want to do, than what you would like them to do. They feel more responsible, and it can cause them, and you, anxiety.
There are households where you are asked to take off your shoes before walking inside. That does prevent tracking in all kinds of filth from the streets and sidewalks. Some of us don't consider this necessary, however, when reviewing the kinds of things that have accumulated, and fermented out there, it does seem like a good idea. Washing the feet of a pet after a walk might not be a bad idea either, especially in a household where there are allergies.
In any case, unless your pet is bathed everyday, and there is a clear understanding of who is the boss of your household, it is not a good idea to allow your pet to sleep in your bed.
It is a good idea to give your pet a special place of their own to sleep. Then your bed will be clean, your pet will be happy, and there will be a long term happy home for all.