A badger that has caused part of a castle in South Lanarkshire to be closed off to the public has left the building.
Staff at Craignethan Castle, near Lesmahagow, tweeted last week that a "very angry badger" was in the cellar tunnel of the property.
Working with animal welfare experts, staff tried to coax the animal from the tunnel with food.
The tunnel was closed on Thursday for the badger and the public's safety.
Historic Environment Scotland, which manages the site, said the tunnel would remain closed until the completion of repairs to damage caused by the badger to some masonry.
The rest of the castle is open to the public.
The badger left the tunnel at some point on Friday night or the early hours of Saturday morning.
Craignethan is a 500-year-old residential tower protected by an artillery fortification.
Badgers are thought to inhabit woodland surrounding the property.