Their colourful faces feature a range of moustaches, nose spots and ear tufts that make each of the 25 or more species in the guenon (Cercopithecini) group of monkeys easily identifiable from one another.

We already know that this distinction helps to avoid crossbreeding, which can produce infertile offspring. This is a big risk for guenons as multiple species often travel, feed and sleep together.

Now scientists have found the monkeys also use facial appearance to recognise friends or foes and generally tell one guenon from another, something that is difficult for most people to do.

Using human facial-recognition techniques and computer algorithms the researchers analysed more than 500 photographs of 12 species of guenons living in zoos in the US and the UK, as well as in a wildlife sanctuary in Nigeria.

“We sought to test a computer’s ability to do something close to what a guenon viewing other guenons’ faces would do,” said lead author William Allen, from the University of Hull, UK.

The computer was able to identify species and individuals from within those species, but it was unable to tell the difference between males and females or categorise the monkeys by age.

The authors say that this is because facial patterns do not differ between males and females, nor do they change with age, suggesting that these characteristics are not important enough to be shown by their faces.

“The fact that species and individual identity can both be reliably classified suggests that the ability to indicate these things to others has been a strong factor in the evolution of guenon faces,” co-author James Higham, from New York University, said.

“More broadly, these results demonstrate that faces are highly reliable for classification by species and that visual cues have played an important role in the radiation of this group into so many different species.”

The findings, reported in the journal Proceedings of the Royal Society B, fit the dynamics found in guenon mixed-species groups, where primates need to identify individual members of their own species but also must avoid mating with other species.

The researchers say their techniques could now be used to study visual signs in other animals.

You can follow BBC Earth on Facebook, Twitter and Instagram.