Zebras got their stripes to avoid tiny, but harmful, predators: bloodsucking horseflies.

That's the conclusion from a new study from researchers from Hungary and Sweden who tested how zebra stripes might influence the attraction tabanids or horseflies have to their victims.

The scientists used boards painted with either black and white strips like zebras or single colors of black, brown, gray or white like regular horses in an effort to find which color lured more horseflies.

The researchers nabbed the blood suckers with oil and glue and found that zebra stripes attracted fewer horseflies.

The stripes repel the insects reflecting light in a polarizing fashion, making a zebra coat look undesirable to the pesky -- and harmful -- critters.

The study was published online The Journal of Experimental Biology (JEB) and will appear in print in the March issue.

The researchers conducted the study in a place where they were guaranteed to find horseflies: a heavily infested Hungarian horse farm, according to a BBC report.

We put insect glue on the boards and counted the number of flies that each one attracted, Susanne Akesson, evolutionary ecologist at Sweden's Lund University and one of the study's authors, told the BBC.

The flies, it turns out, were more likely to be attracted to dark colors than light colors. Scientists said this has to do with the way light bounces off of dark colors, called horizontally polarized light, which is similar to the way light is reflected off of flat surfaces, such as water.

Flies barely touched the striped boards, which scientists believe is due to the way these stripes reflect light.

We conclude that zebras have evolved a coat pattern in which the stripes are narrow enough to ensure minimum attractiveness to tabanid flies, the researchers wrote in a JEB article.

The study's authors believe this could help in future animal breeding efforts.

We have been breeding animals based on meat or milk production, and we haven't paid much attention to their coat colorations or patterns, said Akesson, according to an ABC report. Maybe it's something we need to consider. Maybe there's some trick we can learn from the zebra that could help. 

Not everyone buys the explanation, however, including Martin How, a postdoc at Australia's University of Queensland who studies polarized vision and camouflage. How told New Scientist magazine that it's possible [the stripes] appeared for another reason and the social benefits came later.