The problem with this claim is that it's fairly subjective. The typical claim is that China has 5000 years of unbroken history, suggesting that there was neither downtime in between ruling groups, and that even when the region was in disarray or ruled by foreigners, it still counts as a singular entity.
But this isn't a claim for history, rather a claim for politics. It's particularly problematic as an historical claim considering the first dynasty, the Shang, began only 3615 years ago (give or take), and that its predecessors may not have really existed. Even if we assume the Xia to have existed and not simply as mythology, that only gets us to about 4000 years ago. Anything before that is strictly mythology, and has about as much mathematical value as the genealogies as given in the Old Testament.
In the region that is Greater China, borders changed significantly over the past few thousand years. Ethnicities changed substantially. Languages and language families changed substantially. Cultures merged and died and split and moved.
So, no. It's a handy number, and an oft-repeated one, which has significant sociopolitical value in today's China. But there's no reason to treat it as an historical reality.
hi! if you're interested in more on this, you'll find a recent discussion in this post, which includes links to a few more