Back at Elsinore, Hamlet explains to Horatio that he had discovered Claudius's letter with Rosencrantz and Guildenstern's belongings and replaced it with a forged copy indicating that his former friends should be killed instead. A foppish courtier, Osric , interrupts the conversation to deliver the fencing challenge to Hamlet. Hamlet, despite Horatio's pleas, accepts it. Hamlet does well at first, leading the match by two hits to none, and Gertrude raises a toast to him using the poisoned glass of wine Claudius had set aside for Hamlet. Claudius tries to stop her, but is too late: she drinks, and Laertes realizes the plot will be revealed. Laertes slashes Hamlet with his poisoned blade. In the ensuing scuffle, they switch weapons and Hamlet wounds Laertes with his own poisoned sword. Gertrude collapses and, claiming she has been poisoned, dies. In his dying moments, Laertes reconciles with Hamlet and reveals Claudius's plan. Hamlet rushes at Claudius and kills him. As the poison takes effect, Hamlet, hearing that Fortinbras is marching through the area, names the Norwegian prince as his successor. Horatio, distraught at the thought of being the last survivor and living whilst Hamlet does not, says he will commit suicide by drinking the dregs of Gertrude's poisoned wine, but Hamlet begs him to live on and tell his story. Hamlet dies in Horatio's arms, proclaiming "the rest is silence". Fortinbras, who was ostensibly marching towards Poland with his army, arrives at the palace, along with an English ambassador bringing news of Rosencrantz and Guildenstern's deaths. Horatio promises to recount the full story of what happened, and Fortinbras, seeing the entire Danish royal family dead, takes the crown for himself, and orders a military funeral to honor Hamlet.
The apostrophe of “out, out, thou strumpet, Fortune!” shows Hamlet’s resistance of what he perceives to be the only path available to him. In Act 5 Scene 2, when Hamlet finally takes action, he begins to refer to himself in the third person, a bizarre subversion of a play which previously obsessed with the use of “I”. This switching of mode of speech indicates that it is only though the abandonment of his self-identity, and thus moral code, that he is able to complete the actions which divine providence demands of him. This is supported by Dwery’s reading of the play’s resolution, where he argues that “Hamlet recognizes the inevitability of death, accepting his father’s death and recognising his own unavoidable fate.” (Dwery, 2004) By understanding the contextual concerns with the nature and role of fate and divinity in the everyday, a deeper understanding of the character of Hamlet emerges.