There are many contributing factors which may cause insomnia, such as the pressure of work, studies or sickness. However, another major reason is living habits. An easy solution would be to adopt a healthy lifestyle：exercise regularly, eat healthy food, and think positively. Taking preventive measures to avoid insomnia is much better than resorting to pills. Further ways to stop insomnia include：
I hope this helps you.