Barbary macaques sit in tree branches in a forest near the Moroccan town of Azrou, in the Atlas mountain chain on April 15,…
FILE - Barbary macaques sit in tree branches in a forest near the Moroccan town of Azrou, April 15, 2017. At a German zoo in Loffingen, about 24 Barbary macaques escaped on April 8, 2021. All have been recaptured.

About 24 monkeys escaped from a zoo in the town of Loffingen, Germany, and eluded recapture for several hours, local police said Thursday. 

The Barbary macaques broke out of their enclosure at the Tatzmania wildlife park, police and local media said, about 140 kilometers southwest of Stuttgart, near the border with Switzerland.  

People initially spotted the macaques roaming in a pack in part of Loffingen, and while the monkeys are not large or considered dangerous, the public was warned not to approach or attempt to capture them.  

Zoo workers finally caught up with the fugitives later in the day as they basked in the sun. 

"The animals apparently took advantage of the nice weather and spent the afternoon on the edge of a forest near the zoo," police said. 

While it was unclear exactly how the macaques escaped, police think construction work at the zoo created an opportunity for the monkeys to slip away. 

Barbary macaques are native to mountainous areas of North Africa, zoo officials said, and a small but famous population of them live in the British territory of Gibraltar, where they are known as Barbary apes. They are considered endangered because of severe habitat loss.