The goal of the warring parties was always to put their man on the throne, starting with the death of king Sigurd the Crusader in 1130.
In the first decades of the civil wars, alliances were shifting, and centered around the person of a king or pretender, but eventually, towards the end of the 12th century, two rival parties emerged, known as the birkebeiner and the bagler.
After these two parties were reconciled in 1217, a more ordered system of government centered around the king was gradually able to bring an end to the frequent risings.
The rule of King Haakon and his successors until 1319 has sometimes been called the golden age of the Norwegian medieval kingdom, by later historians.
Under King Haakon Haakonsson, a centralised administration was for the first time built up, with a chancellery in Bergen, which became the first capital city of the country.
Haakon also brought Iceland and Greenland under Norwegian rule, in the early 1260s, at which point the kingdom of Norway reached its largest territorial extent.
These policies, which included complex dynastic ties between the Nordic royal houses, were to lead Norway into several centuries of unions with her neighbours.
The Danish crown was represented by a governor styled Statholder, but it was always important for the King to maintain Norway's legal status as a separate hereditary kingdom.
Norway, which was then governed by Christian's son-in-law, Statholder (royal governor) Hannibal Sehested, was a reluctant participant.
Upon the arrival of Sehested the King joined his fleet and performed heroically, even though wounded, preventing Torstensson's army from moving onto the Danish islands.
Denmark is forced to hand over Gotland, Øsel and Halland (South Sweden) as well as the Norwegian province Jemtland, Herjedalen and Idre & Serna.
As Charles X appeared to be fully occupied in Poland, Frederick III judged the time appropriate for recapture of the other Danish-Norwegian provinces.
Reacting swiftly, by forced marches Charles X attacked Denmark with great success leaving the humiliated Danes with no choice but to sue for peace on any terms.
The terms were brutal: Charles X did not keep the peace and in the remainder of the war the Norwegian army successfully defended Norway from Swedish attacks and recaptured Trøndelag.
Simultaneously with the Danish invasion, an attack against Sweden was also launched from Norway, to force the Swedes to fight a two-front war.
The Swedes mounted a counteroffensive under the command of Magnus Gabriel De la Gardie, sending an army of 8,000 to expel the Norwegian forces.
In August 1710, Baron Løvendal arrived in Norway as governor and commander of a country much drained in resources by the wars of the past century.
Though Allied forces attempted to assist the Norwegians in the defense of their country, they failed and had to retreat and leave Norway to the Nazis.