Q: I started taking potassium pills about five years ago. Then after a few months, I began to have anxiety attacks so severe that I could barely talk to people. Finally, I read warnings about potassium's side effects, which included anxiety attacks. I immediately stopped taking the pills, but still have mild anxiety attacks. More people should know about this side effect.

A: Thank you for sharing what has clearly been a difficult experience. Before we explore the potential risks, however, let's be clear on one point: Humans need potassium for normal cellular function within the body. Major deficiencies in this mineral can lead to severe muscle weakness, failure of the respiratory and gastrointestinal systems, kidney dysfunction, abnormal heart rhythms and possible death. Because many diuretic drugs deplete potassium, people taking such drugs should also take potassium supplements. So too should people with chronic diarrhea, for the same reason.

But if you're not taking medication that decreases potassium, don't have diarrhea and do have a healthy diet, you don't need extra potassium. That doesn't mean people don't take it, however. Some use potassium to ease muscle cramps or to help build muscle through workouts. Others use it as a table salt substitute. Some people even take extra potassium to reduce blood pressure, although there's no evidence that this has any effect.

Humans normally require 2,000 to 3,500 milligrams of potassium daily. Because the mineral is found in a variety of foods, most people's needs can be met through a generally healthy diet. Though it may be tempting to supplement, taking additional potassium can cause your levels to go too high. Because people with kidney dysfunction are already apt to have higher levels of potassium, taking supplements is especially risky for them.

An elevated potassium level can lead to muscle weakness and even paralysis. It can also interfere with electrical conduction in the heart, causing abnormal heart rhythms and, when severe, a shutdown of the heart's electrical activity, meaning loss of any muscle contraction and, quickly, death.

As for the kidneys, although they're efficient at maintaining potassium balance, they can be overwhelmed by high levels, causing them to retain more acid, which leads to metabolic acidosis. In this process, the body tries to decrease acidity in the blood by eliminating carbon dioxide via hyperventilation. (More on this later.)

In your case, I suspect that your potassium levels were too high to begin with. Angiotensin receptor blockers and ACE-inhibitors (both are blood pressure medications) can elevate potassium levels, as can the diuretic spironolactone. And, again, kidney dysfunction can elevate potassium levels as well.

As for your symptoms, it's possible that the high potassium levels led to an abnormal heart rhythm, which in turn led to panic. Another possibility is that the high potassium levels led to greater acidity in the blood — and the ensuing hyperventilation.

That hyperventilation can lead to dizziness, nausea, palpitations, shortness of breath and chest pain — many of the same symptoms as a panic attack.

I'm not sure if my line of thinking is correct, but I do agree that stopping the potassium supplement was the right thing to do. As a next step, I would also recommend that you see your doctor and have both your kidney function and your potassium checked. Those tests may provide some clarity.

Robert Ashley, M.D., is an internist and assistant professor of medicine at the University of California, Los Angeles. Send your questions to askthedoctors@mednet.ucla.edu, or write: Ask the Doctors, c/o Media Relations, UCLA Health, 924 Westwood Blvd., Suite 350, Los Angeles, CA, 90095. Owing to the volume of mail, personal replies cannot be provided.