Shelley uses irony to convey the message that the power of tyrants is fleeting and unstable. Tyrants may delude themselves that their kingdoms and power will last forever, but, in fact, this is not true.
To make his point, Shelley has the poem's speaker use the story of Ozymandias, an ancient ruler. The speaker has met a traveler who tells him of going to an "antique" or ancient land. There, amid a vast desert that spreads out as far as the eye can see, the traveler finds a broken statue of a once mighty, sneering king named Ozymandias. The statue has written on its pedestal the words
My name is Ozymandias, King of Kings;
Look on my Works, ye Mighty, and despair!
The words are ironic, because all of Ozymandias's "Works" are gone, except for his shattered statue. His kingdom is completely lost. The "despair" the mighty should feel is not that Ozymandias is too powerful to dare to contest. Instead, the despair—and warning—to tyrants is that all despots come to the same humiliating end.
Shelley was a radical for his era in that he believed in republicanism and democracy (the governmental form of many, if not most, nations today) rather than monarchy at a time when monarchy was dominant. The poem is cautionary, sending the message to the great that they are not as powerful and invincible as they think.