I think this idea was actually proposed in OTL but rejected. Anyway, the King of Spain decides to turn his New World colonies into autonomous kingdoms, putting his sons (and other prominent nobles) on the thrones of each kingdom, with himself as their overlord of the Spanish Empire.
How might this have impacted history?
It's highly unlikely that the Spanish Empire could have endured into the modern era. However, the kingdoms themselves might have survived. The smarter kings would have dealt with revolutionary sentiment by redirecting it at Spain. Assuming the Napoleonic Wars happened irregardless, that would have been an excellent opportunity for some of those kingdoms to break away completely.
However, there is the little matter of the joker in the deck: the United States. I think that anti-monarchist sentiment in the USA would have been even higher if the New World were dominated by Spanish-derived monarchies. The US-Mexican war would probably have started in a similar fashion, but what if the Kingdom of New Spain were able to call on allies? Or even Spain itself?