Ayr Citadel was built in 1657 on the command of Oliver Cromwell, after the English Civil War and the abolition of the monarchy, to hold down a war weary, hostile Scottish population. It could house a garrison of up to 1000 troops, and was designed to be a huge, impenetrable fortress, bounded on two sides by the sea.
When King Charles II returned to the throne, the Citadel was dismantled to ensure that enemies of the Crown wouldn’t use it ever again. The land was gifted to the Earls of Eglinton, but later came into the ownership of the powerful Kennedy family.
You can still see parts of the old Citadel walls near the harbour in Ayr, but around 1800 the moat was filled in and the surrounding arean was used for private residences.