Denmark–Norway (Danish and Norwegian: Danmark–Norge; also known as the Oldenburg Monarchy or the Oldenburg realms) was an early modern multi-national and multi-lingual real union consisting of the Kingdom of Denmark, the Kingdom of Norway (including Norwegian overseas possessions the Faroe Islands, Iceland, Greenland, et cetera), the Duchy of Schleswig, and the Duchy of Holstein. The state also claimed sovereignty over two historical peoples: Wends and Goths. In addition, the state included the colonies of St. Thomas, St. John, St. Croix, Ghana, Tharangambadi, Serampore, and the Nicobar Islands. The state's inhabitants were mainly Danes, Norwegians, and Germans, and also included Faroese, Icelanders and Inuit in the Norwegian overseas possessions, a Sami minority in northern Norway, as well as indigenous peoples and enslaved Africans in the colonies. The state's main cities were Copenhagen, Christiania (Oslo), Altona, Bergen and Trondheim; its primary official languages were Danish and German. Norwegian, Icelandic, Faroese, Sami and Greenlandic were also spoken.
In 1380, Olaf II of Denmark inherited the Kingdom of Norway, titled as Olaf IV, after the death of his father Haakon VI of Norway, who was married to Olaf's mother Margrete I. Margrete I was ruler of Norway from her son's death in 1387 until her own death in 1412.
Denmark, Norway and Sweden established and formed the Kalmar Union in 1397. Following Sweden's departure in 1523, the union was effectively dissolved. From 1536/1537, Denmark and Norway formed a personal union that would eventually develop into the 1660 integrated state called Denmark–Norway. Prior to 1660, Denmark–Norway was a constitutional and elective monarchy in which the King's power was limited; in that year it became one of the most stringent absolute monarchies in Europe.
The union lasted until 1814, when the Treaty of Kiel decreed that Norway (except for the Faroe Islands, Iceland, and Greenland) be "ceded" to Sweden; this however was not recognised by Norway, which successfully resisted the attempt in the 1814 Swedish–Norwegian War and afterwards entered into a much looser personal union with Sweden as one of two equal kingdoms.
In Norway, the 434-year union with Denmark is often called the 400 Year Night (400-årsnatten). 
The term "Kingdom of Denmark" is sometimes used to include both countries in the period, since the political and economic power emanated from the Danish capital, Copenhagen. These terms cover the "royal territories" of the Oldenburgs as it was in 1460, excluding the "ducal territories" of Schleswig and Holstein. The administration used two official languages, Danish and German, and for several centuries both a Danish and German Chancery existed.
The term "Denmark–Norway" reflects the historical and legal roots of the union. It is adopted from the Oldenburg dynasty's official title. The kings always used the style "King of Denmark and Norway, the Wends and the Goths" (Konge til Danmark og Norge, de Venders og Gothers). Denmark and Norway, sometimes referred to as the "Twin Realms" (Tvillingrigerne) of Denmark–Norway, had separate legal codes and currencies, and mostly separate governing institutions. Following the introduction of absolutism in 1660, the centralisation of government meant a concentration of institutions in Copenhagen. Centralisation was supported in many parts of Norway, where the two-year attempt by Sweden to control Trøndelag had met strong local resistance and resulted in a complete failure for the Swedes and a devastation of the province. This allowed Norway to further secure itself militarily for the future through closer ties with the capital Copenhagen. The term "Sweden–Finland" is sometimes, although with less justification, applied to the contemporary Swedish realm between 1521 and 1809. Finland was never a separate kingdom, and was completely integrated with Sweden, while Denmark was the dominant component in a personal union.
Throughout the time of Denmark–Norway, it continuously had possession over various overseas territories. At the earliest times this meant areas in Northern Europe and North America, for instance Estonia and the Norwegian possessions of Greenland, the Faroe Islands and Iceland.
From the 17th century, the kingdoms acquired colonies in Africa, the Caribbean and India. At its height the empire was about 2,655,564.76 km2 (1,025,319 sq mi)[note 1]
Denmark–Norway maintained numerous colonies from the 17th to 19th centuries over various parts around India. Colonies included the town of Tranquebar and Serampore. The last towns it had control over were sold to the United Kingdom in 1845. Rights in the Nicobar Islands were sold in 1869.
Centred on the Virgin Islands, Denmark–Norway established the Danish West Indies. This colony was one of the longest-lived of Denmark, until it was sold to the United States in 1917. It became the U.S. Virgin Islands.
In the Gold Coast region of West Africa, Denmark–Norway also over time had control over various colonies and forts. The last remaining forts were sold to the United Kingdom in 1850.
The three kingdoms then united in the Kalmar Union in 1397. Sweden broke out of this union and re-entered it several times, until 1521, when Sweden finally left the Union, leaving Denmark–Norway (including overseas possessions in the North Atlantic and the island of Saaremaa in modern Estonia).
The outbreak of the Northern Seven Years' War in 1563 is mainly attributed[by whom?] to Denmark's displeasure over the dismantling of the Kalmar Union in the 1520s. When the Danish king Christian III (reigned 1534–1559) included the traditionally Swedish insignia of three crowns into his own coat of arms, the Swedes interpreted this as a Danish claim over Sweden. In response Erik XIV of Sweden (reigned 1560–1568) added the insignia of Norway and Denmark to his own coat of arms.
After Swedish king Erik introduced obstacles in an attempt to hinder trade with Russia, Lübeck and the Polish–Lithuanian Commonwealth joined Denmark in a war alliance. Denmark then carried out some naval attacks on Sweden, which effectively started the war. After seven years of fighting, the conflict concluded in 1570 with a status quo ante bellum.
Because of Denmark–Norway's dominion over the Baltic Sea (dominium maris baltici) and the North Sea, Sweden had the intention of avoiding paying Denmark's Sound Toll. Swedish king Charles IX's way of accomplishing this was to try to set up a new trade route through Lapland and northern Norway. In 1607 Charles IX declared himself "King of the Lapps in Nordland", and started collecting taxes in Norwegian territory.
Denmark and King Christian IV of Denmark protested against the Swedish actions, as they had no intentions of letting another independent trade route open, Christian IV also had an intent of forcing Sweden to rejoin its union with Denmark. In 1611 Denmark finally invaded Sweden with 6000 men and took the city of Kalmar. On January 20, 1613, the Treaty of Knäred was signed in which Norway's land route from Sweden was regained by incorporating Lapland into Norway, and Swedish payment of the Älvsborg Ransom for two fortresses which Denmark had taken in the war. However, Sweden achieved an exemption from the Sound Toll, which had only previously been secured by Britain and Holland.
The great ransom paid by Sweden (called the Älvsborg Ransom) was used by Christian IV, among many other things, to found the cities of Glückstadt, Christiania (refounded after a fire), Christianshave, Christianstad and Christianssand. He also founded the Danish East India Company which led to the establishment of numerous Danish colonies in India.
Not long after the Kalmar war, Denmark–Norway got involved in another greater war, in which they fought together with the mainly north German and other Protestant states against the Catholic states led by German Catholic League.
Christian IV sought to become the leader of the north German Lutheran states, however following the Battle of Lutter in 1626 Denmark met a crushing defeat. This led to most of the German Protestant states ceasing their support for Christian IV. After another defeat at the Battle of Wolgast and following the Treaty of Lübeck in 1629, which forbade Denmark from future intervening in German affairs, Denmark's participation in the war came to an end.
Sweden was very successful during the Thirty Years' War, while Denmark was a failure. Sweden saw an opportunity of a change of power in the region. Denmark–Norway had a threatening territory surrounding Sweden, and the Sound Dues were a continuing irritation for the Swedes. In 1643 the Swedish Privy Council determined Swedish territorial gain in an eventual war against Denmark–Norway to have good chances. Not long after this, Sweden invaded Denmark–Norway.
Denmark was poorly prepared for the war, and Norway was reluctant to attack Sweden, which left the Swedes in a good position.
The war ended as foreseen with Swedish victory, and with the Treaty of Brömsebro in 1645, Denmark–Norway had to cede some of their territories, including Norwegian territories Jemtland, Herjedalen and Idre & Serna, and the Danish Baltic Sea islands of Gotland and Ösel. The Thirty Years' War thus began the rise of Sweden as a great power, while it marked the start of decline for the Danish.
The Dano-Swedish War (1657–1658), a part of the Second Northern War, was one of the most devastating wars for the Dano-Norwegian kingdom. After a huge loss in the war, Denmark–Norway was forced in the Treaty of Roskilde to give Sweden nearly half its territory. This included Norwegian province of Trøndelag and Båhuslen, all remaining Danish provinces on the Swedish mainland, and the island of Bornholm.
However, two years later, in 1660, there was a follow-up treaty, the Treaty of Copenhagen, which gave Trøndelag and Bornholm back to Denmark–Norway.
In the aftermath of Sweden's final secession from the Kalmar Union in 1521, civil war and Protestant Reformation followed in Denmark and Norway. When things had settled down, the Rigsraad (High Council) of Denmark became weakened, and was abolished in 1660 when Denmark–Norway became an absolutist state and Denmark a hereditary monarchy, as Norway had been since the Middle Ages. These changes were confirmed in the Lex Regia signed on 14 November 1665, stipulating that all power lay in the hands of the king, who was only responsible towards God. The Norwegian Riksråd was assembled for the last time in 1537. Norway kept its separate laws and some institutions, such as a royal chancellor, and separate coinage and army. Norway also had its own royal standard flag until 1748, after that the Dannebrog became the only official merchant flag in the union.
Denmark had lost its provinces in Scania after the Treaty of Roskilde and was always eager to retrieve them, but as Sweden had grown into a great power it would not be an easy task. However, Christian V saw an opportunity when Sweden got involved in the Franco-Dutch War, and after some hesitation Denmark invaded Sweden in 1675.
Although the Danish assault began as a great success, the Swedes led by 19-year-old Charles XI counter-attacked and took back the land that was being occupied. The war was concluded with the French dictating peace, with no permanent gains or losses to either of the countries.
During the French Revolutionary Wars Denmark–Norway at first tried to stay neutral, so it could continue its trade with both France and the United Kingdom, but when it entered the League of Armed Neutrality, the British considered it a hostile action, and attacked Copenhagen in 1801 and again in 1807. In the 1807 attack on Copenhagen the British army confiscated the entire Dano-Norwegian navy on the grounds that Denmark–Norway was about to launch an attack on Britain. The Dano-Norwegian navy had been the only navy left in Europe able to challenge the British navy after the destruction of the Spanish–French navy in the Battle of Trafalgar. The Dano-Norwegian navy was however not prepared for any military operation and the British soldiers found the Dano-Norwegian navy still in dock after the winter season. The Dano-Norwegians were more concerned about preserving their continued neutrality and the entire Dano-Norwegian army was therefore gathered at Danevirke in the event of a French attack, leaving Copenhagen vulnerable to a British attack. The British attack on Danish neutrality effectively forced the Dano-Norwegians into an alliance with Napoleon, and Denmark–Norway allied itself with France.
Denmark–Norway was defeated and had to cede the Kingdom of Norway to the King of Sweden at the Treaty of Kiel. Norway's overseas possessions were kept by Denmark. But the Norwegians objected to the terms of this treaty, and a constitutional assembly declared Norwegian independence on 17 May 1814 and elected the Crown Prince Christian Frederik as king of independent Norway. Following a Swedish invasion, Norway was forced to accept a personal union between Sweden and Norway, but retained its liberal constitution and separate institutions, except for the foreign service. The union was dissolved in 1905.
Denmark–Norway was among the countries to follow Martin Luther after the Protestant Reformation, thus the official religion was established as Lutheran Protestantism throughout the entire life span of the kingdom.
There was however one other religious "reformation" in the kingdom during the rule of Christian VI, a follower of Pietism. The period from 1735 until his death in 1746 has been nicknamed "the State Pietism", as new laws and regulations were established in favor of Pietism. Though Pietism did not last for a substantial time, numerous new small pietistic resurrections occurred over the next 200 years. In the end, Pietism was never firmly established as a lasting religious grouping.