Few causes of sleepless nights . The most common is smashing the stress, so you are overdoing the cortisol release. Removing the cause of the stress is most effective.
Can't shake the causes then drugs. All of these are serious business,even managed;
Anxiety /sleep Drugs;
anxiolytics ..... xanax etc.
Antipsychotics.... lower dose treatments
Hypnotic...... zopiclone etc.
Some info on Melatonin. Supplimentation helps with sleep rythym among other things. It has by various mechanisims the abillity to make a person drowzy, it's not a placebo.
There are many with taxed levels due to factors including prolonged night time exposure to PC / TV screens and most significantly electrical lighting.
Blue wavelengths of visable light suppress the production of melatonin (it is the chief suppression mechanisim based on natural light). The retina in your eye is the feedback mechanisim that regulates production.
You can try changing the lighting in the house to lights that have litte or no blue spectrum and apply a filter to your PC screen to eliminate blue wavelengths of light. For those cluey playing with the gamma settings , try doing this at night and see if you feel drowzy.
Worth knowing melatonin receptor agonists including melatonin have some down significant down sides for training.
Taking it reduces LH (lutenising hormone), FSH production and raises prolactin.