Towards the end of the 12th century the Anglo-Normans constructed a motte-and-bailey fortification here. This was superceeded by a stone structure built in 1210, on the orders of King John of England. The Castle was built by John de Gray, Bishop of Norwich. The 12-sided donjon dates from this time. The rest of the castle was largely destroyed during the Siege of Athlone and subsequently rebuilt and enlarged upon. In the early 1800s, during the Napoleonic Wars, the castle was rebuilt as a fortification to protect the river crossing, taking the form we largely see today. The machicolations of the central keep are all nineteenth century. In the interior is an early nineteenth century two-storey barrack building. The modern ramp up to the castle has a line of pistol loops. The castle was taken over by the Irish Army in 1922 and continued as a military installation until it was transferred to the Office of Public Works in 1970.