Magnesium worked for me when I had that issue. I don't think I've gotten a single nighttime foot cramp since I started taking it.