Good for many purposes in my opinion; replacing alcohol, amazingly horny sex, dancing etc. But for sleep it's just horrid due to the dopamine rebound effect. When it wears of (around three hours) youll be wide awake.
The medical form which is used for insomnia is called Xyrem. And even with that they advice to take one hit to knock you out and straight take the next one when you wake up
Long acting benzo's are better for a good nights rest. But terribly addictive due to long half life. Youll be hooked before you know it.
Ghb you pretty much have to keep upping the dosage in its small half life time in order to become physically addicted.
For the occasional knockout id say Benadryl or Phenergan are good. They dont make you addicted but the effect wears off after some time.