The castle was commissioned by the Scottish King David I in the 1120s.[1] It was taken by the English forces under the terms of the Treaty of Falaise in 1175[1] but then sold back to Scotland by the English King Richard I to fund the Third Crusade in around 1190.[1]
In November 1292, representatives of the English King Edward I arrived in Berwick and announced, in the great hall of the castle, King Edward's adjudication in favour of John Balliol of the dispute between him, Robert the Bruce and the count of Holland for the Crown of Scotland.[2] The castle was retaken by the forces of King Edward I in March 1296 during the First War of Scottish Independence.[3] However, the forces of Robert the Bruce recovered the castle for Scotland in April 1318.[1]
In 1330, "Roberto de Lawedre" of the Bass, described as Custodian or Keeper of the Marches and the Castle of Berwick, received, apparently upon the termination of his employment there, £33.6s.8d, plus a similar amount, from the Scottish Exchequer.[4]
Robert Ogle was captain of the castle in 1435. The castle was worth circa £194 in peacetime, with another £200 to be paid in time of war.[5]
In 1464, the Exchequer Rolls of Scotland record that Robert Lauder of Edrington was paid £20 for repairs made to Berwick Castle.[6] The castle finally fell into English hands in the last week of August 1482, when Richard, Duke of Gloucester captured the castle from Patrick Hepburn, 1st Lord Hailes, during his invasion of Scotland.[7] Planned repairs to the castle in 1483 were entrusted to Alexander Lee, a royal chaplain. The master carpenter of Berwick, George Porter, was ordered to build 120 houses in the town, and chambers, a hall, and a lodging in the castle.[8]
The castle was rendered obsolete by the construction of modern ramparts around Berwick during the reign of Elizabeth I in the late 16th century and it went into steady decline.[9] In August 1590 John Selby reported that a round tower used as the castle's only gun emplacement had collapsed in wet weather.[10] The cost of repair in 1597 was estimated at £200, and John Carey wrote that work was necessary because the gap was wide open to Scotland.[11]
The surveyor of fortifications recommended the demolition of the castle, but in October 1600 Peregrine Bertie, 13th Baron Willoughby de Eresby, Governor of Berwick, was said to have rebuilt some structures for his own use and pleasure.[12]
After the Union of the Crowns in 1603, the military presence in Berwick was scaled down. The Scottish courtier, George Home, 1st Earl of Dunbar began to build a house on the site of Berwick Castle. The master of royal building work in Scotland, James Murray of Kilbaberton was involved in the construction.[13][14] The mansion was never finished but was widely rumoured to be magnificent. George Chaworth wrote to the Earl of Shrewsbury in 1607 about its size, height, views, and good proportions and that its long gallery would make that at Worksop Manor look like a garret or attic.[15] According to William Brereton, who visited Berwick in 1633, the building work ended at the Earl's death in 1611. A stately "platform" was begun, and a long gallery with a large mantlepiece (5 yards long) had a flat roof for promenaders to view the landscape.[16]
Large parts of the castle structure were reused as masonry in the 17th century, including for the construction of the parish church, Holy Trinity, during the Commonwealth.[17]