You're tired and cranky. Maybe you have issues with your heart rhythm or have trouble sleeping. The problem may be caused by a lack of magnesium.

As with most nutrients, our bodies need magnesium to stay healthy. It's found naturally in many foods, but according to the USDA, only about half of all adults get the daily recommended amount. When we don't get enough, it's not always obvious; the symptoms can be vague and are similar to the symptoms of many other disorders.

Here are some of the problems that can be caused by a lack of magnesium.

Nausea and vomiting

Early signs of magnesium deficiency can include gastrointestinal disturbances. This can range from a loss of appetite to nausea and vomiting.

Blood pressure

Many studies have shown a link between magnesium levels and blood pressure. In those studies, volunteers with low magnesium were more likely to have hypertension, or high blood pressure. However, research that uses magnesium therapy to treat hypertension has offered conflicting results. In some cases it has been successful, but not for all.

Sleep problems

Chronic insomnia and other sleep disorders may have a link to magnesium deficiency. Several studies have suggested that magnesium supplements may play a key role in regulating sleep.

Anxiety and depression

Somecase studies have shown a link between magnesium and the nervous system. In some instances, the mineral seems to have a positive effect on stress, anxiety and some symptoms of depression.

Heart issues

Although low levels of magnesium can affect nearly every system in the body, one of the most significant impacts can be on the heart. People who are deficient in the mineral are prone to arrhythmia — or abnormal heart rhythm. In related studies, people with coronary artery disease had a higher incidence of magnesium deficiency than those without the illness.

Restless legs syndrome

The cause of RLS is often not clear, but it sometimes can be linked to an underlyingmedical condition such as a vitamin or mineral deficiency. Low levels of magnesium may contribute to other sleep disturbances and some small studies have shown that magnesium supplements can help with RLS.

Low energy

Several studies have suggested that too little magnesium makes the body work harder. In a recent small USDA-funded study, volunteers used more oxygen during physical activity when their magnesium levels were low. It doesn't matter if you exercise a lot or not. "The effects are likely to occur in individuals with low magnesium, regardless of whether the person is athletic or sedentary," says lead researcher physiologist Henry C. Lukaski. "That means that athletes wouldn't be able to work or train as long as they would if they had better magnesium levels. People need to eat adequate magnesium to make sure their hearts and muscles are healthy enough to meet the demands of daily living."

Muscle spasms and weakness

Magnesium has been shown to stabilize the nerve axon — the nerve fiber that transmits information away from the nerve cell body. When the amount of magnesium drops, the result is hyperresponsive neuromuscular activity which can mean muscle tremors, spasms and eventually weakness.

spinach salad with nuts - almonds are a rich source of magnesiumA spinach salad topped with walnuts will provide a meal rich in magnesium, offering roughly 120 mg. And if you want to get an even bigger boost, swap out the walnuts for almonds. (Photo: MSPhotographic/Shutterstock)

Where do I get magnesium?

Adult women should get about 310 mg of magnesium daily; adult men should get 400 mg. That increases to 320 mg for women and 420 for men after age 30.

You can get magnesium in green leafy vegetables, legumes, nuts and whole grains. Generally, foods that are rich in dietary fiber usually are rich in magnesium. The mineral is also added to some fortified foods, including breakfast cereals.

Here are some good sources of magnesium, according to the National Institutes of Health:

  • Almonds, dry roasted, 1 ounce: 80 mg
  • Spinach, boiled, 1/2 cup: 78 mg
  • Cashews, dry roasted, 1 ounce: 74 mg
  • Peanuts, oil roasted, 1/4 cup: 63 mg
  • Cereal, shredded wheat, 2 large: 61 mg
  • Soy milk, plain or vanilla, 1 cup: 61 mg
  • Black beans, cooked, 1/2 cup: 60 mg
  • Edamame, shelled, cooked, 1/2 cup: 50 mg
  • Peanut butter, smooth, 2 tablespoons: 49 mg
  • Bread, whole wheat, 2 slices: 46 mg
  • Walnuts, 1 ounce: 45 mg
  • Avocado, cubed, 1 cup: 44 mg
  • Potato, baked with skin, 3.5 ounces: 43 mg
  • Rice, brown, cooked, 1/2 cup: 42 mg
  • Yogurt, plain, low-fat, 8 ounces: 42 mg

Mary Jo DiLonardo Mary Jo writes about everything from health to parenting — and anything that helps explain why her dog does what he does.