Quick note for anyone reading this about magnesium glycinate: this form of magnesium contains an amino acid called glycine, and we have evidence that glycine can improve sleep quality. According to examine.com, the evidence is "very high" that:
>In persons undergoing mild sleep deprivation, 3g of glycine an hour prior to sleep is able to increase sleep quality and improve self-reports of fatigue and well being the next day due to better sleep.
I take approx. 10g of gelatin a day which also contains glycine, and I also notice improvements in my sleep.