Experts recommend getting rid of pesky flies by making a homemade fly trap using vinegar and a glass container, removing foods that attract flies, sealing doors and windows, and luring flies outside towards a light source. Other tactics are vacuuming and swatting flies with a fly swatter.
Homemade fly traps work best for eliminating a fruit fly invasion, and are made using an empty glass jar or bottle, pouring a quantity of apple cider vinegar into the bottle, then sticking a paper funnel into the jar so flies can crawl into the liquid. An alternative to the funnel is to cut a plastic food bag to fit over the top of the jar, and secure it with a rubber band. Snip a hole in the middle of the plastic so flies can enter. Adding a slice of banana or apple to the mixture increases its aromatic appeal for fruit flies. Seal the jar and discard it after several hours of accumulating flies.
Getting rid of house flies involves removing uncovered food that attracts them and either placing food in a container, in the refrigerator or discarding it. Clean food crumbs off of counters and tables, remove uneaten pet food from food bowls and keep garbage cans covered at all times. Burning a citronella candle outside helps keep flies at bay.