To get rid of fruit flies in the kitchen, throw out any old or overripe fruit in the kitchen or pantry, clean out the sink drain and purchase or make fruit fly traps to contain and kill the remaining flies. Fruit flies are attracted to fruit, juice and other organic materials, so it is important to keep these items in closed containers or in the refrigerator until the infestation is under control. Fruit flies are small flying insects that live for approximately 30 days. They can reproduce quickly, so it can take some time to eliminate them completely from an infested kitchen.
Clean the kitchen
Use fly traps
Dispose of any exposed fruit because it could have eggs inside it, then clean all surfaces and appliances to ensure there is no organic matter out in the open. Clean out the trash can as well, and then clean the disposal to eliminate all attractants.
Homeowners can purchase fly traps meant specifically for fruit flies, but there are also several homemade fly trap recipes. Set a piece of ripe fruit in a mason jar, then add a paper cone to the top to trap the flies. Alternatively, fill a jar with vinegar, fruit juice or wine, and then cover the top with plastic wrap and punch tiny holes in it.