Most people associate bats with sucking blood. While they do suck blood, the more dangerous aspect to humans is their feces and bites. If you have a bat infestation you need to learn a little more about the type of bat you have and then learn how to get rid of it. Once you get the bats out of your home, you need to then work to prevent them from getting back in.
Most bats that get onto homes are just looking for a place to stay during the day. They do not like light and prefer the dark, coolness of an attic. They usually leave at night to hunt for food.
The only real way to keep bats out of your home is to make sure they can not get in. You should check around your roof area for holes or spaces where they could get in and seal them off. Also check your chimney to make sure it has no holes or openings and that your chimney trap is working properly. You can seal the holes with the material of your choice. Bats can not chew through materials to get in. Before sealing you should make sure all the bats that are inside have left. The best time is at night when they will leave to hunt.
Bats do not like fiberglass insulation, so if you do not have any installed in your attic then you may consider doing so if bats are a huge problem. You can also leave on the lights or use a fan in the area as this will deter bats also. Some bird repellents will also work to keep bats away when it is applied to the area around entrances.
While bats can be harmful, they generally only create a nuisance. They are quite helpful because they eat other pests that you may not want in your home. If you have bat problems, you may want to call a professional who can help you best deal with your situation.