The Battle of Dunbar was fought between the English New Model Army, under Oliver Cromwell, and a Scottish army commanded by David Leslie on 3 September 1650 near Dunbar, Scotland. The battle resulted in a decisive victory for the English. It was the first major battle of the 1650 invasion of Scotland, which was triggered by Scotland's acceptance of Charles II as king of Britain after the beheading of his father, Charles I on 30 January 1649. After Charles I's execution, the English Rump Parliament established a republican Commonwealth in England. When their erstwhile ally, Scotland, recognised Charles II as king of all of Britain on 1 May 1650 and began recruiting an army to support him, the English dispatched the New Model Army, under the command of Cromwell. The army crossed into Scotland on 22 July, with a force of over 16,000 men. The Scots withdrew to Edinburgh, stripping the land of provisions. Cromwell attempted to draw the Scots out into a set piece battle, but they resisted, and Cromwell was unable to break through their defensive line. At the end of August, with his army weakened through disease and lack of food, Cromwell withdrew to the port of Dunbar. The Scottish army followed and took up an unassailable position on Doon Hill, overlooking the town. On 2 September, the Scots advanced towards Dunbar and the English took up positions outside the town. The English army was greatly weakened by sickness and lack of food, while many of the Scots' most experienced men had been dismissed in religious purges. Before dawn on 3 September the English launched a surprise attack on the Scots, who were poorly prepared. The fighting was restricted to the north-eastern flank with the main contingents of English and Scottish cavalry fighting inconclusively, as did the English and Scottish infantry. Due to the terrain Leslie was unable to reinforce the fighting, while Cromwell used his last reserve to outflank the Scots. The Scottish cavalry broke and routed; the Scottish infantry made a fighting retreat but suffered heavy casualties. Between 300 and 500 Scots were killed, approximately 1,000 wounded and at least 6,000 were taken prisoner from an army of 12,500 or fewer. After the battle, the Scottish government took refuge in Stirling, where Leslie rallied what remained of his army. The English captured Edinburgh and the strategically important port of Leith. In the summer of 1651