I've taken melatonin for sleeping. I used the sublingual tablet that goes under your tongue. I worked for me, in 15 min more or less. About migraines, my son claims that his have never returned since he had his wisdom teeth taken out.