St Andrews Castle is the ruins of the castle of the Archbishops of St Andrews, dating in part from the 13th century.