How can I improve my sleep quality and get rid of insomnia?

How can I improve my sleep quality and get rid of insomnia?