Increasing your dietary intake of magnesium from food may not be sufficient if your body has insufficient magnesium levels. The University of Kansas Medical Center states that while supplements could help you replace your magnesium stores, recovering from severe shortages might take up to six months of treatment.