My favorite is this:
There are more things in heaven and earth, Horatio,
Than are dreamt of in your philosophy.
The quote has no real significance in the scope of the plot and is almost an aside, but it conveys an absolute truth about life and the world at large: human beings, both individually and collectively, are infinitely complex and represent a multitude of cultures, beliefs, practices, habits, accomplishments, ways of living etc. So much so that one can hardly dream of the vast richness of human culture.
Those who believe that Shakespeare couldn't have possibly been one individual often cite the vast knowledge and experience that the characters and storylines of his play exhibit. That is, he demonstrated such a wealth of knowledge in so many different disciplines that it's beyond comprehension that it would have been one author behind the plays. Whether that is true or not is up for debate, but the author of the quote above realized that there are far more things in the human experience than one person can possibly know.
What is a important line or quote and why is it important?
There are many famous and important lines from Hamlet, but the most famous line is "To be or not to be," the opening line of Hamlet's most famous soliloquy from Act III scene 1. It is important because it sums up both the existential dilemma that all humans face (the meaning of life, and its pains) and Hamlet's own character. He waffles over everything, even over whether to live or die.
(For a fun reference to this, see the cartoon below.)