Dastan (Jake Gyllenhall) is the adopted son of King Sharaman who grows up in the royal palace alongside the king's sons. On a conquest, Nizam (Ben Kingsley), the king's brother and counsel, advises the princes Tus and Garsiv to invade the holy city of Alamut. Meanwhile, Tamina (Gemma Arterton), the princess of Alamut entrusts a mystical dagger to one of her subjects.
Based on the game created by Jordan Mechner, the movie is a CG-suffused action adventure with a classic heroic story at its heart.
Dastan, who is not yet considered ready for battle, decides to secretly aid the Persian conquest by breaching the eastern wall, thereby securing victory for the Persians. The subject with the dagger is killed on his way out by Dastan who assumes it to be an ordinary dagger and keeps it. When Nizam suggests a matrimonial alliance between the future king, Tus and the princess Tamina, she agrees when she notices the dagger with Dastan.
Back in Persia, when the cloak that Dastan presents to the king turns out to be poisoned, he is assumed to be an assassin. He escapes with Tamina into the desert where they are caught by a group of bandits headed by the ostrich-racing Sheik Amar (Alfred Molina) who later becomes an ally.
With Tamina's help, Dastan learns of the mystery surrounding the mystical dagger. It becomes the key to uncovering the identity of the secret group of terrorists called Hassansins and the plot behind the king's assassination. Using the dagger, Dastan saves the Persian empire even as he absolves himself of the blame of killing the king.