When he states "get thee to a nunnery" to Ophelia, he is expressing pent-up anger towards his mother, who he feels has been unfaithful and incestuous when she married his uncle. At the beginning of the play itself, we see a brooding Hamlet who seems almost more upset by his mother's marriage than by his father's death. He speaks of it with such bitter disgust: "She married, O, most wicked speed, to post with such dexterity to incestuous sheets!" (I.ii.156-7) and is so upset with his mother that he pronounces a curse on ALL women, not just her: "Frailty, thy name is woman!" (I.ii.147). So, that curse includes Ophelia, and from that point on, he avoids her. Then, when she confronts him, he lets out a huge rant on all women in general-it is a way to indirectly vent his rage at his mother, since he suspects she is listening.
So, think of a nunnery. There, women cannot marry at all; they cannot be under the influence of any men, or influence men in any way. Hamlet feels that is where a woman has a best chance at being faithful, and where she will cause the least amount of damage. After all, as he tells Ophelia also, "why wouldst thou be a breeder of sinners?"; in a nunnery, she won't have children and bear wicked men-like his uncle-that do awful things. A nunnery will keep her from marrying, but if she were to marry, Hamlet says, "be thou as chaste as ice, as pure as snow...[or] marry a fool" who doesn't know "what monsters you make of them" (III.i.122-146).
I hope that explanation helps a bit! Good luck!
Hamlet has turned against women because of his mother's behavior. He still loves Ophelia but decides against marrying her. When he tells her to get to a nunnery, he is revealing his love for her. He doesn't want to marry her, but he doesn't want her to marry anybody else. His behavior at Ophelia's funeral in Act 5, Scene 1shows how deeply he loved her--more than "forty thousand brothers" could love her.
Both the sources from which we get the tale of Hamlet- Saxo Grammaticus's "Historica Danica" and Belleforest's French translation of it, Ophelia is employed as a decoy by the King and his officials. This speech shows a moralistic Hamlet preaching the doctrine that man is an inherent Sinner.
It is from the beginning that Hamlet's misogynist views already hold sway over his mind. Due to his mother's hasty marriage, considered incestuous by religious standards, Hamlet condemns women in general for he sees that they are more susceptible to the carnal pleasures and are at times mislead by honeyed words.
It is not only Hamlet who holds this opinion. Laertus also cautions his sister in Act I. Hamlet's opinion is further supported by Polonius. Shakespeare shows Polonius's true colours when he agrees to use his daughter as a pawn in unraveling the cause of Hamlet's madness. doing so is also a way of furthering his favor with the King. It is this duplicity in Polonius that makes Hamlet call him a "fishmonger."
Hamlet assumes that Ophelia and Polonius are hand in glove, plotting against him together, still he admires her before berating her. On her return of his love letters and trinkets, he further denigrates women ironically for not being able to decide (his own weakness). To a maddened, spurned lover the best place for a woman to be is in the "nunnery."
The pretense of chastity can be dropped in a brothel because deceit and the "paintings" are a part of a wanton woman's life. This speech shows a moralistic Hamlet preaching the doctrine that man is an inherent Sinner.
It is possible that Hamlet tells Ophelia to 'get thee to a nunnery' as a gesture of protection. He may feel that a nunnery would keep her away from the afflications and dangers of this world. However, it is also likely that Hamlet is referring to the nunnery as a brothel in which it shows his disgust for her. Hamlet is an ambigious character <3
In my opinion Hamlet tells Ophelia to 'get thee to a nunnery' as he believes all women are deceitful. In particular he is basing his knowledge on his mothers actions- She remarried after one month of his fathers death to his brother. His fury and anger are taken out on Ophelia as she tries to give Hamlet back some 'remembrances'. He berates Ophelia and cruelly tells her not to have children because she would be a
breeder of sinners
This scene is one of the few times we see Hamlet loose his composure. It indeed is dramatic and compelling as it serves a catalyst for much of the plays subsequent action.
Hamlet suspects Ophelia has betrayed him by being willing 'bait' for her father's spytrap.
A few minutes before, Hamlet was very close to killing himself, so think about his emotional state, he's feeling a total fragile wreck. Then along comes Ophelia, his much-loved girlfriend. ... and she finishes with him. She returns his love-letters and poems and gifts. Ouch! That's not good timing.
Then, Hamlet realises they are being spyed on. He suddenly suspects Ophelia is a willing accomplice to this covert operation and that she's cheerfully dumped him in public to get a reaction.
He does what many love-sick, unhappy, rejected ex-boyfriends do when they can't have the girl they love. He rages. For some reason, we reserve the worst insults for the ones we love. He calls her names and tries to hurt her feelings.
Also, he may be 'playing to the gallery', aware that they are being spied on, he may be exagerating his 'madness'. But considering he was moments from suicide and his girlfriend just dumped him, he probably didn't need to act too hard.
Hamlet feels betrayed on all sides. When he knows Polonius and Claudius are eavesdropping on his conversation with Ophelia, he point blank asks her "Where is your father?" To which Ophelia replies, "At home, my lord." Enranged, Hamlet now tells her to get to a nunnery so as not to breed sin. The verbal irony here is that "nunnery" in Elizabethan England was a slang term for a brothel. Hamlet may be protecting Ophelia, wanting her to get away from all the sin in the rotton State of Denmark; however, mist critics agree that he is transfering his anger from his mother, Gertrude, onto all women. He turns misogynistic, seeing all women as dependent, sexual beings. None are to be trusted.
"Get thee to a nunnery" : a place where Ophelia can remain chaste and not continue the procreation of wicked sinful creatures. Even the most ordinary men are full of sins. Hamlet enumerates his.
Presumably, Hamlet might be referring to a convent, where Ophelia will be cleansed of her sins and to be far away from the 'rotten' state of Denmark. On the other hand, "nunnery" was a euphemism for "brothel" in Elizabethan time, probably Hamlet was underscoring that, because beforehand, he calls Polonius a "fishmonger" which is de facto a slang term for agent of prostitutes.
"Get thee to a nunnery" is a play on words. Although a nunnery is a place for pure women who give themselves body and soles to God, a nunnery also means a whore house. Nunnery has a double meaning. Essentially, Hamlet is telling Ophelia that she is both pure and impure.
Hamlet is full on crazed by this time since he believes that all women in fact are double faced including his mother. When he understands that he is being spied on, he believes Ophelia is behind all this and turns from loving her into spurning her, thinking she is just using him as another excuse as his mother did as well. Since he is extremely angry at this he tells her to go to a nunnery.
He relates Ophelia to his mom who has entered the marriage with his uncle and believes it to be a sin. He believes that Ophelia is like his mom, two-timing, and then changes from almost loving to almost craze and madness. He rants about his anger towards his mother and towards the fair Ophelia and turns that into insanity.
Hamlet is stunned by Ophelia's "duplicity", and already being horrified by his mother's own treachery, sees Ophelia as a typical "two faced woman". So in a rage he denounces her and all of womankind.
Hope that helps.