An epic new history of the final 300 years of Germany's first Reich reveals how the period gave birth to modern German identity and principles that still underpin its attempts to lead Europe today.

A decade in the making, Germany and the Holy Roman Empire (1493-1806), by the University of Cambridge historian Dr Joachim Whaley, is the most comprehensive survey of Germany's early modern history ever undertaken, the first book of its kind since the 1950s, and one of the most substantial works of historical scholarship published in the UK this year.

The two-volume study tells the story of more than 300 principalities and about 1,500 other minor territories. Together, these made up the later Holy Roman Empire, which covered much of northern and central Europe and constituted Germany's original Reich.

Whaley believes that their story challenges much of what we think we know about Germany and its people today. With Europe in crisis and many nations looking to Germany for leadership, he argues that the period reveals a deeper history of political co-operation and consensus, which is usually overlooked because of Germany's recent, often darker past. Today, the very word "Reich", which has associations with the disastrous Third Reich, has become taboo. The first Reich was very different.

Historians themselves have also neglected the last three centuries of the Holy Roman Empire. Typically, the period has been portrayed as one of decline, in which the Empire fragmented into warring territories, was split by the Catholic-Protestant divide of the Reformation, was ravaged by the Thirty Years War, and eventually became meaningless. Even some well-respected histories of Germany give its final decades only a handful of pages.

After 10 years researching and writing the book, Whaley argues that it is time to look again. Rather than a weak, dysfunctional precursor of the strong Germany that emerged in the 19th century, the new study suggests that the latter-day Holy Roman Empire was a successful political entity in itself.

What we struggle with, he adds, is that its model was very different to our own idea of what a "state" should be. In an era before nations, the Empire was a "federative state" - made up of territories with interlocking identities. People saw themselves as both local and German, but there was no Imperial capital and ‘Germany’ comprised territories that today are part of France, Belgium, Poland, the Czech Republic and Austria, as well as the Federal Republic of Germany. While this political system may sound alien now, the book argues that by and large, it worked.

"The history of German-speaking Europe in this period has been seen as the history of localities and territories, but it is also the history of the union of those entities and their survival," Whaley said. "Usually historians see this time as one of division in which the Empire failed to function as a nation state. What we forget is that for 300 years, it also held the German-speaking territories together as a legal and cultural community, in spite of numerous changes and external threats."

This community, the study suggests, laid much of the groundwork for German identity today. It began in the 1490s, when the Emperor Maximilian I and the German princes and cities carved out a two-tier system of government based on the concept of Kaiser und Reich. At one level, the Emperor provided governance in negotiation with the princes through the diet, the Reichstag. At the same time, however, all of the territories essentially governed themselves.

Although subject to their immediate ruler, people were also vassals of the Emperor and could appeal to the laws of the Reich as a greater authority. While this led to some periods of instability and even war, Whaley argues that overall, it created a political climate of negotiation, consensus and co-operation, and the recognition that each sub-region of the Empire had certain freedoms.

The result was a 300-year period of evolution. Maximilian's changes were just the first of different phases of reform which usually emerged because of religious differences, economic problems, social unrest, or wars. Each time, the two-tier system adapted to accommodate the hundreds of territories it contained.

The Holy Roman Empire never experienced a direct equivalent of the English Civil War or the French Revolution, but the Thirty Years War was perhaps an equivalent. At one level, this was a European war fought largely on German soil. At another level, it was a conflict over the German constitution and another, albeit traumatic evolutionary phase: Ferdinand II aimed to subvert the constitution and establish a strong monarchy; the German princes ultimately succeeded in having the old balance of powers restored. In 1648 the Peace of Westphalia refined and renewed the principles established by Maximilian and the German princes around 1500 and this treaty remained the fundamental constitutional law of the Reich for the next 150 years.

The study argues that this gave early-modern Germany a progressive system of governance. In spite of its highly fragmented state, there was a consistency about the way the different territories dealt with issues like judicial reform, welfare or education. As a result, the community constantly evolved a picture of itself as German: "There was a clear sense of the difference between the extensive rights and liberties they enjoyed as subjects of the Empire compared with, say, the subjects of the king of France," Whaley says.

In times of war, the Emperor was still therefore able to raise an army that had the patriotic fervour needed to defend the Empire's borders. Critically, however, German identity became associated with the principles of the federative state - the protection and preservation of local rights, and unity in diversity. It failed only when it came under overwhelming military pressure from France after 1792 and was dissolved at Napoleon’s insistence in 1806.

Whaley's analysis stops short of claiming that the later Holy Roman Empire was the forerunner of a modern federal Europe. He does, however, suggest that it helps to explain how Germany perceives Europe, and why Germans find the notion of a united Europe more palatable than, for example, the British.

"There is a history here of co-operation, consensus and compromise in German politics which is rarely acknowledged," he says. "For Germans, there is a federal mentality and habit that is deeply ingrained. This expects to deal with things by compromise and works slowly to broker deals and find ways to move forwards. Understanding the history of the Reich cannot help us to construct a blueprint for the future of Europe, but it can help us understand how Germany and Europe have become what they are today."

Germany and the Holy Roman Empire (1493-1806) is published by Oxford University Press.