As the climate warmed up, forceful rivers of meltwater started to flow and shape the virgin lands, and more stable flora and fauna gradually began emerging in Scandinavia, and Denmark in particular.
The first human settlers to inhabit Denmark and Scandinavia permanently were the Maglemosian people, residing in seasonal camps and exploiting the land, sea, rivers and lakes.
The first inhabitants of this early post-glacial landscape in the so-called Boreal period, were very small and scattered populations living from hunting of reindeer and other land mammals and gathering whatever fruits the climate was able to offer.
During the Pre-Roman Iron Age (from the 4th to the 1st century BC), the climate in Denmark and southern Scandinavia became cooler and wetter, limiting agriculture and setting the stage for local groups to migrate southward into Germania.
At this early stage there is no evidence that the Danish Church was able to create a stable administration that Harald could use to exercise more effective control over his kingdom, but it may have contributed to the development of a centralising political and religious ideology among the social elite which sustained and enhanced an increasingly powerful kingship.
During the disastrous reign of Christopher II (1319–1332), most of the country was seized by the provincial counts (except Skåne, which was taken over by Sweden) after numerous peasant revolts and conflicts with the Church.
During her lifetime (1353–1412) the three kingdoms of Denmark, Norway, and Sweden (including the Faroe Islands, as well as Iceland, Greenland, and present-day Finland) became linked under her capable rule, in what became known as the Kalmar Union, made official in 1397.
This became apparent once word got out that King Frederick and his son, Duke Christian had no sympathy with Franciscans who persistently made the rounds of the parishes to collect food, money, and clothing in addition to the tithes.
The State Council (Danish: Rigsråd) on Zealand, led by the Catholic bishops, took control of the country and refused to recognize the election of Christian III, a staunch Lutheran.
Count Christopher raised an army (including troops from Mecklenburg and Oldenburg and the Hanseatic League, especially Lübeck) to restore his Catholic uncle King Christian II (deposed in 1523).
The Catholic Church everywhere in Scandinavia had sealed its fate by supporting hopeless causes: Christian II and the emperor Charles V in Denmark, Norwegian independence in that country, and in Sweden the Kalmar Union.
The Danish economy benefited from the Eighty Years' War (1568–1648) in the Netherlands because a large number of skilled refugees from that area (the most economically advanced in Europe) came to Denmark.
European politics of the 16th century revolved largely around the struggle between Catholic and Protestant forces, so it seemed almost inevitable that Denmark, a strong, unified Lutheran kingdom, would get drawn into the larger war when it came.
The result of this defeat proved disastrous for Denmark–Norway: in the Second treaty of Brömsebro (1645) Denmark ceded to Sweden the Norwegian provinces Jemtland, Herjedalen and Älvdalen as well as the Danish islands of Gotland and Øsel.
In the following Treaty of Roskilde, Denmark–Norway capitulated and gave up all of Eastern Denmark (Danish: Skåne, Halland, Blekinge and Bornholm), in addition to the counties of Bahusia (Norwegian: Båhuslen) and Trøndelag in Norway.
Three months after the peace treaty was signed, Charles X Gustav of Sweden held a council of war where he decided to simply wipe Denmark from the map and unite all of Scandinavia under his rule.
As a result of the disaster in the war against Sweden, King Frederick III (reigned 1648–1670) succeeded in convincing the nobles to give up some of their powers and their exemption from taxes, leading to the era of absolutism in Denmark.
[19] Empress Catherine withdrew her husband's demands and negotiated the transfer of ducal Schleswig-Holstein to the Danish crown in return for Russian control of the County of Oldenburg and adjacent lands within the Holy Roman Empire, an exchange that was formalized with the 1773 Treaty of Tsarskoye Selo.
In the 1770s, during the reign of the mentally unstable Christian VII (1766–1808), the queen Caroline Matilda's lover, a German doctor named Johann Friedrich Struensee, became the real ruler of the country.
In 1772, Struensee was arrested, tried, and convicted of crimes against the majesty, his right hand was cut off following his beheading, his remains were quartered and put on display on top of spikes on the commons west of Copenhagen.
In contrast to France under the ancien regime, agricultural reform was intensified in Denmark, civil rights were extended to the peasants, the finances of the Danish state were healthy, and there were no external or internal crises.
Christian IV (reigned 1588–1648) first initiated the policy of expanding Denmark's overseas trade, as part of the mercantilist trend then popular in European governing circles.
In favour of the Kingdom of Prussia, Denmark renounced her claims to Swedish Pomerania at the Congress of Vienna (1815), and instead was satisfied with the Duchy of Lauenburg and a Prussian payment of 3.5 million talers.
Extensive agricultural improvements took place in Jutland, and a new form of nationalism, which emphasized the "small" people, the decency of rural Denmark, and the shunning of wider aspirations, developed.
Even though constitutional changes had taken place to boost the power of the Landsting, the Left Venstre Party demanded to form the government, but the king, still the head of the executive branch, refused.
In an outcome not initially foreseen, the perceived security led to a situation where the formally separate currencies circulated on a basis of "as good as" the legal tender virtually throughout the entire area.
During this time women gained the right to vote (1915), and the United States purchased some of Denmark's colonial holdings: the three islands of St. John, St. Croix, and St. Thomas in the West Indies.
The king and parts of the opposition grumbled that Prime Minister Carl Theodor Zahle (in office 1909–1910 and 1913–1920) did not use Germany's defeat to take back a bigger portion of the province, which Denmark had lost in the Second Schleswig War in 1864.
1953 saw further political reform in Denmark, abolishing the Landsting (the elected upper house), colonial status for Greenland and allowing female rights of succession to the throne with the signing of a new constitution.
[35] Denmark went through some of its most serious post-war crises in the early 21st century, such as the SARS outbreak in 2003, Indian Ocean tsunami in December 2004,[36][37][38] Jyllands-Posten Muhammad cartoons controversy in 2005, Danish embassy bombing in Islamabad in 2008, Copenhagen attacks in 2015, and with the COVID-19 pandemic (including Deltacron hybrid variant) in between January 2020 and March 2022, which has further damaged the economy.