German nationalism (German: Deutscher Nationalismus) is an ideological notion that promotes the unity of Germans and of the Germanosphere into one unified nation-state. It emphasises and takes pride in the patriotism and national identity of Germans as one nation and one people. German nationalism, and the concept of nationalism itself, began during the late 18th century, which later gave rise to Pan-Germanism. Advocacy of a German nation-state became an important political force in response to the invasion of German territories by France under Napoleon Bonaparte. In the 19th century, Germans debated the German question over whether the German nation-state should comprise a "Lesser Germany" that excluded the Austrian Empire or a "Greater Germany" that included the Austrian Empire or its German speaking part. The faction led by Prussian Chancellor Otto von Bismarck succeeded in forging a Lesser Germany.
Aggressive German nationalism and territorial expansion were key factors leading to both World Wars. Before World War I, Germany had established a colonial empire, which became the third-largest, after Britain and France. In the 1930s, the Nazis came to power and sought to unify all ethnic Germans under the leadership of Adolf Hitler, eventually leading to the extermination of Jews, Poles, Romani, and other people deemed Untermenschen (subhumans) in the Holocaust during World War II. After the defeat of Nazi Germany, the country was divided into East and West Germany in the opening acts of the Cold War, and each state retained a sense of German identity and held reunification as a goal, albeit in different contexts. The creation of the European Union was in part an effort to harness German identity to a European identity. West Germany underwent its economic miracle following the war which led to the creation of a guest worker program; many of these workers settled in Germany which led to tensions around questions of national and cultural identity, especially with regard to Turks who settled in Germany.