The Twists: The Man in Black is revealed to be Westley. Vizzini dies from drinking poison (both cups were poisoned, Westley was immune). Count Rugen is the six-fingered man.
The Ending: Westley, Buttercup, Inigo, and Fezzik escape the castle on four white horses. They do not kill Prince Humperdinck; instead, Westley spares his life but leaves him humiliated and tied to a chair, condemned to live with his cowardice. In the framing story, the grandfather finishes the book. The grandson, now fully invested, asks him to come back and read it again tomorrow. The grandfather replies, 'As you wish,' confirming his love for the boy.