Who protects your daily security? Who does your loyalty belong to?
Initially (in the middle ages), the answer was your local nobleman, and, through him, via the duke and/or kind, to the Holy Roman Emperor.
Someone had to provide peace, and the choice was limited: whoever has won military control over your area most recently.
As long as they did not interfere with your religious life and did not assess too much taxes, it was okay.
One's ethnicity was a private matter - like religion today.
The French revolution offered a practical implementation of what was spelled out by the thinkers of the Enlightenment - that "someone" is not really necessary, We The People can handle our peace ourselves.
This meant that you don't have to chose your suzerain from the existing list, you join forces with your neighbors and create a better country.
Napoleon's military successes illustrated that idea: you do not have to be lead by blue blood.
Trade was growing in importance (industrial revolution &c), and, thus, infrastructure (roads &c) became critical.
Thus replacing one's loyalty to some remote potentate who didn't even speak your language with a someone local makes a lot of sense.
Printing press made books cheap, so literacy started to make sense even for lower classes. Printing in vernacular languages was a response to that. Thus the European society transformed itself from "educated people communicate in Latin, especially long distance" to "people read and write in a local language". This lead to an intellectual fragmentation of Europe:
Across Europe, the increasing cultural self-awareness of its peoples led to the rise of proto-nationalism, accelerated by the flowering of the European vernacular languages to the detriment of Latin's status as lingua franca.