This is an extraordinarily complicated issue of geopolitics and ethno-nationalism that historians grapple with to this day! However, there is fortunately one short, conventional answer to your question. The Mandate of Heaven!
It's strange to think of the Chinese Empire as a somewhat theocratic institution, but that's how the cookie crumbles here. Without the "divine" right to rule granted to the Emperor as Son of Heaven by Confucian ideology, there's no way Chinese rule would have remained so stable and consistent in form.
Before I get into what this Mandate and philosophy of succession really entails, I do want to advise you against historical generalism in this matter. While the Chinese state was relatively stable, (since we're comparing it to Europe here), it was hardly peaceful or unwavering. The narrative of Chinese history is a story of constant foreign incursion, domestic uprising, political infighting, and slow yet steady reform. Check out the maps of each Chinese dynasty and marvel at how much the borders shift over time. Consider how rarely the Chinese court stuck to one capital for more than a century, and how nearly every dynasty was toppled by interior coup or popular rebellion!
However, it's still extraordinarily that, while the occupant of the throne changed so often, the institutions surrounding said throne were pretty omnipresent. This is where we get into explaining the philosophy of Chinese right to rule.
As early as the Zhou, China's second imperialistic state, Chinese princes were citing a supernatural or "heavenly" suitability to rule as justification for their elevated status^1. This isn't anything radically unique, just political propaganda that assured the populace that the emperor rules divinely because of his superhuman virtue and favor of the spiritual world.
However, the hidden genius of the Mandate of Heaven is the fact that it carries an internal explanation for political power changing hands. In fact, it can even be wielded as something of a weapon against unusual tyranny. This is because the principle states that, should a prince lose the Mandate of Heaven, he loses the right to rule and should be deposed by any means necessary. Rebels throughout Chinese history utilized this tool as a way to mobilize the populace, convincing them that it wasn't really treachery to rise against a ruler without the Mandate. Dynasties supplanting and deposing one another wasn't revolution, merely a transfer of the old Mandate of Heaven.
This explains the cultural consistency between so many ethnically and ideologically diverse dynasties. If you want to rule over Imperial China for any real length of time, you need the Confucian right to rule, you need the Mandate of Heaven. This, in part, explains the intense Sinofication undergone by foreign rulers like the Mongol Yuan and Manchurian Qing. Essentially, if you want to rule China, you need the elite to back you, as they can guide the actions of the commoners. The Confucian-educated elite want a good, Confucian Son of Heaven.
So that's the Mandate of Heaven, and why it ensured cultural and political consistency amongst so much upheaval and strife. In Europe, a popular revolt may spell the end of an entire form of government, the turning upside-down of a whole society. In China, this wasn't the case, as deeply-ingrained Confucian principles like the Mandate of Heaven provided a guiding ideal for rulers and rebels alike.
Source: 1- Szczepanski, Kallie. "What Is the Mandate of Heaven in China?". About Education. Retrieved December 4, 2014.
While cause and effect are difficult to prove for these matters, the contrast may also have something to do with geographical fragmentation of Europe versus the presence of the two big river valleys in China which formed the core of Chinese civilization, the Yangtze and especially the Yellow river valleys. You could follow these rivers very far into the interior facilitating travel and transport and of course, political control. Traffic between the two river areas was facilitated by the construction of the Grand Canal. There are also large areas of relatively flat (not necessarily low) land around these rivers especially in the North. It is not a coincidence that the capitals of the various dynasties tended to be in the North or sometimes in the lower Yangtze valley area.