An historic 14th century tower is to be handed over to the care of the National Trust for Scotland.
The Alloa Tower, in Clackmannanshire, is the first heritage property acquired by conservation charity in seven years.
The ancestral home of the Erskine family, the Earls of Mar and Kellie, it has been run as a popular visitor attraction since being restored in 1996.
The tower is the largest, oldest keep in Scotland and was originally built to guard the nearby ferry crossing on the River Forth.
The Erskines were aides to the Stuart monarchs and guardians to the royal children.
Mary Queen of Scots and James VI both spent part of their early lives at Alloa Tower and it was Mary who conferred an earldom on the Erskines in 1565.
“This is the culmination of many extraordinary acts of dedication and generosity,” said Sir Kenneth Calman, chairman of the National Trust for Scotland.
“Through collective devotion played out over almost 30 years, we have assured the survival of a place that was at the nexus of events that shaped Scottish history.
“Since its construction around 1368, Alloa Tower has been altered many times and it provides a rich tapestry of architectural styles and historic collections.
“It is wonderful addition to the Trust’s portfolio.”
Among Alloa Tower’s features are a sweeping 18th century Italianate staircase, a medieval oak beamed roof, a dungeon and a well.
It also houses collections of important paintings, including works by Raeburn and Van Dyck, and silverware.
NTS says it intends to improve the reception area of the tower, enhance the visitor experience and engage more with the local community.