The play is about revenge. Should an individual seek revenge when they are wronged? What type of revenge is best, mental or physical? These are a couple of the questions the play seeks to answer, and Shakespeare brilliantly explores these questions when Hamlet has his uncle watch The Mousetrap play (mental revenge) and when Hamlet ultimately kills Claudius (physical revenge) in act 5, scene 2.
Think about Hamlet's second soliloquy in act 2, scene 2. He comes up with the idea to show his uncle The Mousetrap play which reenacts the murder of Hamlet's father. In this situation, Hamlet believes that revenge is best served as mental anguish for the victim Claudius.
Think about Hamlet's soliloquy in act 4, scene 4. Here, he sees the army of Fortinbras marching through the snow, and this inspires a different type of revenge. Hamlet now shifts his focus to a physical revenge. He decides that his course of action should be to shed the blood of Claudius. In act 5, scene 2, Hamlet carries out the murder of Claudius.
But is it worth it to seek revenge? This is a question the audience should be asking itself at the play's conclusion. Human nature makes us feel loyalty to our family members. When those family members are harmed or wronged, we feel like we can bring justice to the situation by taking mental or physical revenge. Hamlet dies while carrying out his revenge mission, so some audience members might decide that revenge is not worth the trouble. Shakespeare might be trying to tell audiences that seeking revenge can cause more problems than it solves.