
How to Get Rid of House Flies
How to get rid of flies in your house: remove what they breed in, block entry, then trap, swat or spray the rest. Plus the vinegar trap and what fails.

- Step 1
- remove breeding source: trash, pet waste, compost
- Step 2
- screens, door sweeps, seal gaps
- Step 3
- fly tape, traps, swatter, or a spray
- Time to clear
- 1–3 days for adults if source removed
- DIY cost
- about $10–$40
Updated October 15, 2026. We added safety guidance: for each product, how dangerous it is for cats, dogs, kids, pregnancy, fish and birds, how to protect your household, and what to do if someone is exposed.
To get rid of flies in the house, first remove what they breed in (open trash, pet waste, compost, or a dead animal) and close the gaps they use to get in, then kill the ones already inside with fly ribbon, a swatter, or a quick pyrethrin spray. If you only do the last part, new flies replace the dead ones within days.
House flies breed outdoors and in garbage, not in your walls, so control is mostly about sanitation and screens. UC IPM puts it bluntly: flies found indoors almost always came from outside, and poor exclusion and poor sanitation are the main causes of fly problems. Here is the order that works.
Step 1: Identify the fly
This plan is for house flies (1/4 inch, gray, four stripes on the back) and their larger relatives, blow flies. If yours are different, use the right guide:
- tan with red eyes, around fruit → fruit flies
- tiny and black, near houseplants → gnats
- fuzzy and moth-like in the bathroom → drain flies
- slow, clumsy flies on fall or winter windows → cluster flies
- large, shiny green, blue, or black flies concentrated in one room → probably a dead animal; see Step 2
Not sure? Compare on the house flies page.
Step 2: Remove the breeding source
House flies lay batches of 100 to 150 eggs in warm, moist, rotting material, and in summer the maggots become adults in as little as a week. Extension guides call sanitation the mainstay of fly control, so start here:
- Trash: use cans with tight lids, bag food waste, and take it out at least twice a week in summer (UC IPM's minimum is weekly). Rinse the can and lid monthly. Keep bins as far from doors as practical.
- Pet waste: pick up dog waste daily; scoop litter boxes daily.
- Compost: keep it covered, bury fresh scraps under brown material, turn it regularly, and do not add meat. Unturned piles and wet grass clippings also breed biting stable flies.
- Food: do not leave pet food out; clean up grill grease and spills.
- Dead animal: a sudden swarm of big blow flies in one room points to a dead mouse, rat, or bird in a wall, ceiling, attic, or crawl space. Follow the flies and the smell (there may be none), remove it if you can reach it, and vacuum up any maggots or brown pupal cases nearby. If you cannot reach it, the flies stop on their own once the last pupae hatch, usually within one to two weeks.

Step 3: Keep flies out of your house
- Repair torn screens and fit screens on every window you open. Standard 16- to 18-mesh window screen keeps house flies out.
- Add door sweeps and weatherstripping.
- Close gaps around window AC units, dryer vents, and pipes.
- Keep doors closed, especially near the grill or trash area; a self-closing screen door or a magnetic mesh curtain helps on doors that open constantly.
- For cluster flies, seal attic, soffit, and siding gaps in late summer, before they move in. The University of Kentucky notes window screens do not stop them because they enter through tiny gaps in the walls.

Step 4: Kill the flies already inside
| Method | Best for | Notes |
|---|---|---|
| Fly swatter / electric swatter | a few flies | cheap and works; not over food prep areas |
| Fly ribbon (sticky tape) | garages, porches, kitchens | UC IPM: effective for a few flies in confined spaces, not heavy infestations |
| Window sticky traps | flies gathering on glass | great for blow flies and cluster flies, which head to light |
| Vacuum | sluggish cluster flies, blow flies on windows | empty the canister outside |
| Enclosed UV trap with glue board | kitchens, continuous low numbers | works indoors where it is not competing with daylight |
| Pyrethrin aerosol | many flies at once | fast knockdown, no lasting effect; follow the label |
Blow flies rarely land on vertical surfaces, so UC IPM notes that hanging ribbons catch few of them; put sticky traps on windowsills and flat surfaces instead.
Using spray safely. Indoor flying-insect sprays usually contain pyrethrins or synthetic pyrethroids. Remove or cover food, dishes, and pet bowls, keep people and pets out of the room until it airs out, and cover aquariums, because these chemicals are highly toxic to fish. Always follow the EPA-registered label; the label is the law. House flies have developed resistance to many insecticides, which is one more reason spraying alone tends to disappoint.
How dangerous are these products
Most fly control here is physical: swatters, ribbons, sticky and UV traps carry no chemical risk. The products with real risk are pyrethrin aerosols, and foggers and fly baits, which this page doesn't recommend as a main tool.
Comparison table




















Aerosols
Spray in short bursts in an empty room, then close it for the time on the label and air it out before anyone returns. Cats and birds are the most sensitive: cats can't break down some pyrethroids, and birds' lungs take in anything in the air. Cans are flammable, so keep them away from pilot lights and stoves.
Fly baits
Baits are sugary and attractive to dogs. Use them only in stations or places pets can't reach, and never scatter them where kids play.
If something goes wrong
- On skin. Wash with soap and water. Tingling or numbness after a pyrethroid is common and fades within hours.
- In eyes. Rinse with running water for 15 minutes; see a doctor if burning continues.
- Swallowed. Don't induce vomiting. Call Poison Control at 1-800-222-1222 and have the product label in hand.
- A pet ate it or acts strangely (tremors, drooling, vomiting, wobbling, seizures). Call your vet or the ASPCA Animal Poison Control Center at (888) 426-4435 right away, and bring the package.
- Fish acting distressed (gasping at the surface, darting). Change a large part of the water and run a filter with activated carbon.
How to get rid of house flies with vinegar
A vinegar trap works best on fruit flies, but it catches some house flies too:
- Fill a jar with an inch of apple cider vinegar and a spoonful of sugar.
- Add one drop of dish soap so flies sink.
- Cover with plastic wrap and poke a few holes, or roll a paper funnel into the mouth.
For house flies, better homemade baits are a bit of overripe fruit or sugar water with a splash of fruit juice in a narrow-neck bottle. Outdoors, cone-shaped baited fly traps with a commercial lure work very well, but they smell strongly; UC IPM advises placing them well away from the house and notes they work only when they are not competing with nearby garbage or animal waste.
How to keep flies out of the yard and patio
- Pick up dog waste daily and keep compost covered.
- Hang baited traps well away from doors and seating (at the edge of the yard) so they pull flies away from people instead of toward them.
- Use a box fan on the patio table; flies avoid steady airflow.
- Clean grills and outdoor trash cans regularly.
- If you have little house flies hovering in slow circles under a porch roof, they ignore house fly baits and traps; UC IPM recommends finding their breeding site (often manure, compost, or wet grass clippings) and using strong fans where they swarm.
What does not work
- Bags of water with pennies: no evidence they repel flies.
- Bug zappers: house flies are weakly drawn to UV, and UC IPM warns zappers scatter insect fragments over several feet; never use them near food.
- Essential oil sprays and herb pots: at best a mild, short-lived effect.
- Foggers: kill some flies but do nothing about the source, and leave residue on surfaces.
- Baits alone: Nebraska and UC IPM both say fly baits fail when flies have access to garbage or waste.
What people who dealt with it say
- The "clean house, still flies" mystery is usually a dead animal. In r/pestcontrol threads about sudden swarms of big black or green flies, the most common answer, and most common outcome, was a dead mouse in a crawl space, ceiling, or wall. People who put a sticky trap on the window where the flies gathered and waited saw the flies stop within a week or two. A pro's summary: there is no chemical treatment; once all the pupae hatch, it ends.
- Expect waves. When the source is hidden, flies can come in batches a week apart until it is used up. Check under rugs, curtains, and anything lying on the floor for crawling maggots or brown pupal cases.
- Exclusion pays off. The top answers in a big r/homeowners discussion of pest-free homes were sealing gaps and screens, taking kitchen trash out daily, and not leaving food out, with spraying a distant last.
How long it takes
If the source is gone and doors are screened, adults inside are gone in one to three days. Blow flies from a dead animal typically stop in 10 to 14 days. If flies keep appearing for more than two weeks, there is still breeding nearby: a hidden carcass, a neighbor's compost or dumpster, or pet waste in the yard.
When to call a professional
Call a pest professional if you cannot find the source, if there is a dead animal in a wall or crawl space you cannot reach, or if cluster flies come back every year. Pros can treat exterior siding and eaves before fall and set commercial-grade traps. A one-time service typically costs about $150 to $300 (approximate). Compare products in bug sprays.
FAQ
How do I get rid of flies in the house quickly?
How do I get rid of house flies with vinegar?
How do I keep flies out of my house?
What is the best way to kill house flies?
Why do I keep getting flies even though my house is clean?
Do bug zappers work on house flies?
How do I get rid of small flies in the house?
Sources and real-world experience
Built from the expert sources and real discussions below — we read each one. How we research.
- UC IPM: Flies (Pest Notes)
- University of Nebraska-Lincoln Extension: House Fly Control Guide (G958)
- University of Kentucky Entomology: Cluster Flies, Face Flies, and Blow Flies in Homes (ENTFACT-624)
- University of Kentucky Entomology: Fruit Flies (ENTFACT-621)
- Reddit r/pestcontrol: Large black flies have suddenly appeared in my home
- Reddit r/pestcontrol: Sudden infestation of blowflies in house (green bottle fly)
- Reddit r/homeowners: How do so many people just have absolutely no bugs in their house?