[header] How to get rid of flies in the kitchen [title] Eliminate the obvious sources of attraction for fruit flies. [step] Place ripened fruit and vegetables out of sight and into the refrigerator to prevent fruit flies from having a breeding source. Throw any rotten produce away. 
[title] Empty recycling bins and trash cans regularly to avoid fruit flies and houseflies. [step] Clean the sides and bottom of the garbage can and bin so that they are free of food and juices on their surfaces.