The film's major twist lies in Princess Fiona's curse. While Shrek assumes she is a perfect princess who judges him for his looks, it is revealed she turns into an ogre at sunset. She hides this because she believes she is unlovable in that form.
The climax disrupts the wedding between Fiona and Farquaad. Shrek confesses his love, and as the sun sets, Fiona transforms in front of everyone. Farquaad is eaten by the Dragon (who has fallen in love with Donkey). The final subversion occurs when Shrek and Fiona share true love's first kiss. The spell states she will take "love's true form." Instead of turning back into a human, she remains an ogre permanently. This confirms that her "true form"—the one where she is happiest and most authentic—is as an ogre with Shrek, shattering the expectation that a happy ending requires physical perfection.