Magnesium-rich foods include leafy green vegetables like spinach and kale, nuts, seeds, whole grains, and legumes. Magnesium is also added to some breakfast cereals and other fortified foods.