This castle was made out of timber structures enclosed by a ringwork (a circular earthwork). The ringwork was fortified with timber defenses and enclosed by a deep ditch, which still exists, partially filled with water. On the ditch's south bank, a bailey, or enclosure, existed. This was where the soldiers of the castle would have lived. The original castle was built in about 1180 by Henry II to protect his border with Scotland. It was later expanded by his son, King Edward I, who visited the castle on several occasions. In 1307, the Scottish invaded and took control of the castle for three days before it was reclaimed by Edward's forces. In 1316, another invasion force from Scotland captured the castle but they were again defeated by Edward's men. In total, the castle changed hands seven times between the Scots and English until it was finally agreed that the castle should be shared between them, so it could be used as a border fortification instead of being taken over by invaders. After the war, the king ordered that the castle be demolished because it was considered expensive to maintain. The ruins of the castle are all that remain today of Middleham Castle.