You've probably watched a fly land on the table, stop, and slowly rub its front legs together like a cartoon villain. It looks like it's plotting something. So why do flies rub their hands? The short answer is hygiene. A fly's legs do jobs that our hands, tongue and nose do for us, and they only work well when they're clean.
Researchers have studied fly grooming in surprising detail, mostly in fruit flies coated in dust under a camera. Here's what they've found, plus what it means when a fly lands on your sandwich.
Quick facts
Dust-covered fruit flies clean in a fixed order: eyes, then antennae, then abdomen, wings and thorax, according to a 2014 Janelia Research Campus study published in eLife.
In that study, flies broke off every so often to rub their legs together and shed the dust they'd collected.
Fruit flies have sweet-sensing taste neurons in their legs that stop them walking when they step on food, a 2016 Tohoku University study in Nature Communications reported.
House flies grip ceilings with two pads under each foot called pulvilli, covered in tiny hairs that release a sticky secretion (Live Science, 2006).
A 2019 UC Santa Barbara analysis of more than 40 hours of video from 92 flies found single grooming movements usually last 150 milliseconds to 2 seconds.
Why do flies rub their hands together?
Flies rub their hands together to clean their front legs, which collect dust and debris as the fly grooms its head. The "hands" are the tips of the front legs. Entomologists call the foot segments the tarsi.
In 2014, Julie Simpson and Andrew Seeds at the Howard Hughes Medical Institute's Janelia Research Campus dusted fruit flies and filmed them cleaning up. The front legs swept the eyes and antennae first. Then the back legs took over the abdomen, wings and thorax. The full paper describes cyclic bouts of leg rubbing. Once the legs had picked up enough dust from sweeping, the fly rubbed it toward the tips and got rid of it.
So the hand rubbing you see on your kitchen counter is often one step in a longer cleaning routine. The fly wipes its face with its front legs, then rubs those legs against each other to clear them. Rubbing the back legs together does the same job after the fly cleans its wings and body.
Flies taste with their feet
Flies taste with their feet, so dirty feet make it harder for them to find food. Their legs carry taste sensors, a type of chemoreceptor (a sense organ that detects chemicals by touch), sitting at the base of tiny hairs.
The 2016 Tohoku University team led by Vladimiros Thoma showed how much fruit flies rely on these leg sensors. When the researchers blocked the sweet-sensing neurons in the legs, hungry flies no longer went straight for sugar. Some leg neurons stop the fly in its tracks as soon as it steps on food. Others signal the brain to start feeding.
The same sensors pick up danger. A 2015 review in Frontiers in Integrative Neuroscience notes that bitter-sensing taste hairs on fruit fly wings and legs respond to extracts of E. coli bacteria. Touching bitter quinine or those bacterial extracts set off grooming. In other words, a fly can taste something nasty on its body and then clean it off.
Mark Elgar, a professor at the University of Melbourne, says flies taste with their feet (Pursuit, 2015). Butterflies share the trick, which is one of several differences covered in our moth vs butterfly guide.
Clean feet stick better
Clean feet also help a fly walk upside down. Each house fly foot has a pair of claws and, beneath them, two soft pads called pulvilli, according to Britannica.
A team led by Stanislav Gorb at Germany's Max Planck Institute for Metals Research described how these pads work in 2006. The pulvilli are covered in hairs (setae) with flattened, spatula-shaped tips. Those hairs release a glue-like secretion of sugars and oils. The claws help the fly peel its feet off again so it doesn't get stuck.
That grip depends on close contact between the hair tips and the surface. Dust, pollen and dried food sitting on the pads would get in the way, which is one reason researchers think flies spend so much effort on their legs. The Janelia flies cleaned their legs throughout the grooming sequence, not only at the end.
What does it mean when flies rub their hands together?
When a fly rubs its hands together, it means the fly is grooming. The fly is clearing debris from its legs, whatever the internet says about plotting.
The "what are you planning" joke is one of the internet's longest-running fly memes, and it's easy to see why. Hand rubbing looks like a human gesture of scheming or anticipation. For the fly, though, it's routine maintenance.
Grooming is also tightly organized. The 2014 Janelia study found a suppression hierarchy: dirt on the head gets priority, and cleaning the head holds back cleaning of the body. When the team switched on abdomen cleaning in dusty flies, the flies cleaned their heads, then kept scrubbing their abdomens and ignored the rest. Simpson suggested the same kind of system may help explain how animals string movements into complex sequences.
Why do flies rub their hands and face?
Flies rub their face to clean their eyes and antennae, then rub their hands to clear the dirt they just wiped off. The eyes and antennae come first in the fruit fly cleaning order, ahead of the abdomen, wings and thorax.
That order makes sense when you think about what's on a fly's head. The large compound eyes are how it spots movement, including your hand coming down. The antennae detect smells that lead it to food and egg-laying sites. A fly with dusty eyes or antennae is slower to find a meal and slower to escape.
A 2019 study by Mueller and colleagues at UC Santa Barbara found early grooming focuses on the head and front legs. Over roughly 13 minutes, the flies gradually shifted toward the back of the body and spent more time walking. If you've ever seen a fly wash its face, rub its hands, and then work its back legs over its wings, you've watched that whole routine.
Why do flies land on you and your food?
Flies land on you and your food because both taste good to them. Professor Elgar told Pursuit that flies feed on our sweat and skin secretions, which contain proteins, carbohydrates, salts and sugars, along with dead skin cells and bacteria.
A freshly groomed fly is clean only by fly standards. Dr Maggie Hardy of the University of Queensland told ABC News in 2016 that flies are fastidious about cleaning themselves. That doesn't make their feet safe for your food. Britannica notes that house flies may carry millions of microorganisms on their feet.
How they eat adds to the problem. The Illinois Department of Public Health says house flies spit up stomach contents onto food to liquefy it before eating. They may also defecate on food and surfaces, and they can spread food poisoning and dysentery. The University of New Hampshire Extension lists salmonella and E. coli among the organisms house flies can transmit.
There's also a seasonal clue. Writing in the CDC journal Emerging Infectious Diseases in 2005, Gordon Nichols linked weekly Campylobacter cases in England and Wales (1989 to 1999) to house fly breeding conditions. He proposed that flies may be a major route for this food poisoning bug in kitchens. It's a hypothesis, not settled fact, but it's a good reason to keep flies off your plate.
Do other insects rub their hands?
Yes, many insects groom, and some use special structures on their legs to clean their antennae. Flies are the ones people notice most because they do it in plain view on tables and windows.
Some insects have gone further. A 2022 study in Communications Biology by Nadein and Gorb found that the Congo rose chafer, a digging beetle, has brushes and scrapers inside its front leg joints. They wipe away soil every time the joint bends, with no grooming needed. If you're curious about other insect body quirks, our piece on why bees die after stinging explains how a honey bee's barbed sting works. And if grooming in general interests you, cats are just as obsessive, as we explain in why cats hate water.
You can browse more insect behavior in our insects and bugs section.
Frequently asked questions
Why do flies rub their hands together?
Flies rub their hands together to clean their front legs. The legs pick up dust and debris while the fly wipes its eyes and antennae. Rubbing them together scrapes that material off the taste sensors and sticky foot pads.
Why do flies rub their legs together?
Flies rub their legs together to keep the feet clean enough to taste and grip. Fly feet carry taste receptors and hairy adhesive pads called pulvilli, and both work best without a layer of dust or food residue.
What does it mean when flies rub their hands together?
A fly rubbing its hands together is grooming. The gesture looks like scheming to people, but researchers studying fruit flies at Janelia Research Campus found it is one part of a set cleaning routine.
Why do flies rub their hands and face?
Flies rub their face to clean their eyes and antennae, which they use to spot danger and smell food. Fruit flies clean these head parts first, then rub their front legs together to get rid of the dirt.
Do flies really taste with their feet?
Yes, flies taste with their feet. A 2016 Tohoku University study found that sweet-sensing neurons in fruit fly legs make a hungry fly stop walking when it steps on food and help trigger feeding.
Is a fly that rubs its hands clean enough to touch my food?
No, a grooming fly can still contaminate food. House flies spit up stomach contents onto food and may defecate on it, and public health agencies link them to food poisoning and dysentery.
Sources
Dust-Covered Flies Reveal Hidden Logic of Grooming Behavior, Howard Hughes Medical Institute
A suppression hierarchy among competing motor programs drives sequential grooming in Drosophila, eLife (Seeds et al., 2014)
Drosophila melanogaster grooming possesses syntax with distinct rules at different temporal scales, PLOS Computational Biology (Mueller et al., 2019)
Toe Taste Sensors Help Flies Find Food, Asian Scientist
Drosophila Bitter Taste(s), Frontiers in Integrative Neuroscience
How Flies Walk on Ceilings, Live Science
Housefly, Encyclopaedia Britannica
Why flies and mosquitoes are irritating little pests, University of Melbourne Pursuit
The House Fly and Other Filth Flies: Prevention and Control, Illinois Department of Public Health
House Fly fact sheet, University of New Hampshire Extension
Fly Transmission of Campylobacter, Emerging Infectious Diseases (CDC)





Comments