Irritable bowel syndrome (IBS) is a gastrointestinal disorder characterized by a group of symptoms that usually occur together, including:

IBS is thought to be caused by problems between how the brain and the intestines work together. Doctors now refer to conditions like IBS as disorders of gut-brain interactions.

Some people with IBS have constipation. Some have diarrhea. Others fluctuate between the two. For this reason, IBS is often categorized into different types:

  • IBS with constipation (IBS-C): abnormal bowel movements with stools that are hard or lumpy; fewer bowel movements overall, sometimes require straining
  • IBS with diarrhea (IBS-D): stools are loose or watery; may have abdominal pain along with more frequent urges to go
  • IBS with mixed bowel habits (IBS-M): abnormal bowel movements that can be both hard and lumpy and loose or watery in the same day

If you have IBS, you may have heard that magnesium could help ease your symptoms.

While increasing magnesium-rich foods could be beneficial for everyone with IBS, certain formulations of magnesium supplements are specifically known to help ease constipation.

For this reason, magnesium supplements may be helpful for people with IBS-C or IBS-M but may not be a good idea for those with IBS-D as they can increase diarrhea.

Read on to learn more about the potential benefits and risks of taking magnesium for treating IBS.

Magnesium is a mineral involved in many essential functions in the body, including regulating muscle and nerve function, blood pressure, and blood sugar. Magnesium can be found in a wide variety of foods, including:

  • leafy greens
  • potatoes
  • broccoli
  • whole grains
  • avocados
  • legumes, like lentils, chickpeas, and peas
  • seeds, like flaxseed and pumpkin seeds
  • tofu
  • some types of fish
  • nuts
  • dark chocolate

However, some people don’t get enough magnesium and turn to supplements to help boost their intake.

Magnesium supplements are thought to help ease abdominal cramping, anxiety, and constipation. For this reason, increased dietary magnesium and magnesium supplements may be recommended to help with symptoms commonly experienced in people with IBS-C.

Stool softener

Magnesium draws water into the intestines, which softens and increases the size of the stool. This helps to make stools easier to pass.

Reduces anxiety

Magnesium has been shown to reduce anxiety. Since anxiety may aggravate symptoms of IBS, this may help reduce symptoms.

Although magnesium is generally considered safe for most people, you may have side effects after taking a supplement, especially if you take too much.

To avoid side effects, try to keep intake to under 350 mg per day, unless under the supervision of a doctor.

The most common side effects of magnesium supplements include:

  • mild diarrhea
  • nausea
  • stomach cramps


The Food and Drug Administration (FDA) does not regulate supplements the same way that medications are. Supplements may contain additional ingredients that are not listed on the label or different amounts of ingredients than are listed on the label.

It’s important to choose reputable brands that have undergone quality testing.

Was this helpful?


Taking magnesium supplements at high doses can cause more serious side effects, such as:

  • mild diarrhea
  • nausea
  • abdominal pain
Medical Emergency

Very large doses of magnesium (more than 5,000 mg/day) have been associated with magnesium toxicity, which can be fatal. Symptoms of magnesium toxicity include:

The risk of magnesium toxicity is higher in people with kidney problems.

If you encounter any of these side effects, stop taking magnesium and call your doctor or the poison control helpline at 1-800-222-1222.

Allergic reaction

It’s possible to have an allergic reaction to magnesium or any of the other ingredients contained in a food or supplement.

Symptoms of an allergic reaction may include rash or hives, itching, trouble breathing, and other symptoms.

Medical Emergency

Call 911 if you’re having trouble breathing or symptoms of a severe allergic reaction, such as:

  • skin reactions, such as hives, itching, or pale skin
  • wheezing or trouble with breathing
  • lightheadedness, dizziness, or fainting
  • facial swelling
  • nausea
  • weak and fast pulse

Drug interactions

Magnesium supplements are known to interact with certain types of medications, such as:

  • certain antibiotics, including tetracyclines (like demeclocycline and doxycycline), and quinolone antibiotics (like ciprofloxacin and levofloxacin)
  • bisphosphonates, such as alendronate (Fosamax), used to treat osteoporosis
  • diuretics, including furosemide (Lasix) and hydrochlorothiazide (Aquazide H)
  • certain drugs used to ease symptoms of acid reflux or treat peptic ulcers that may also contain magnesium, like esomeprazole magnesium (Nexium) and lansoprazole (Prevacid)

If you’re considering taking a magnesium supplement to treat IBS, speak with a doctor first to discuss any other supplements and prescription or over-the-counter medications that you already take.

Magnesium supplements are available in a variety of forms. Each one will differ in absorption rates.

Keep in mind that the Food and Drug Administration (FDA) does not review supplements for safety and effectiveness and should be taken with caution.

Look for brands that are certified by third parties, like NSF International, for safety and quality.

Ask your doctor before taking any supplements and be sure to read all product labels for the correct dosage.

While there are many types of magnesium available, magnesium oxide, magnesium citrate, magnesium sulfate, and magnesium hydroxide have been shown to have an osmotic laxative effect that could help treat constipation in people with IBS.

Magnesium citrate for IBS

Magnesium citrate is magnesium in combination with citric acid.

Magnesium citrate is considered an osmotic laxative. It works by relaxing your bowels and pulling water into the bowels. The water helps soften and bulk up your stool, making it pass through more easily.

Magnesium citrate can be found in capsule, liquid, or powder formulations (that you mix with water). You don’t need a prescription to purchase magnesium citrate. It can be easily found in drugstores or online.

The recommended dose for magnesium supplements depends on brand, intended use, and how much magnesium you already get in your diet. Follow the dosage on the package instructions.

Magnesium sulfate for IBS

Magnesium sulfate, also known as Epsom salt, is one type of magnesium salt that may improve constipation.

A 2016 study, for example, showed that consumption of mineral water containing magnesium sulfate improved the frequency of bowel movements in people with IBS-C.

However, the effect only lasted up to 6 weeks.

A 2017 study with closely related research parameters and methods to the study previously mentioned showed similar results.

To treat constipation, adults and children ages 12 years and older can dissolve 2 to 4 level teaspoons of Epsom salt in 8 ounces of water and drink immediately.

Magnesium hydroxide for IBS

Magnesium hydroxide (milk of magnesia) works as a laxative by pulling water into your intestines, which helps soften your stool and ease its passage.

The recommended dose varies based on the product.

Phillips’ Milk of Magnesia, for example, recommends taking 2 to 4 tablespoons (30 to 60 mL) per day, with each tablespoon (15 mL) containing 1,200 mg of magnesium hydroxide.

While this is considered above the safe upper level, the laxative effect of this is desired in such a case.

Other magnesium formulations

There are several other types of magnesium supplements available. However, these formulations may not be the best option for treating constipation.

  • magnesium chelate
  • magnesium aspartate
  • magnesium threonate
  • magnesium glycinate
  • magnesium malate
  • magnesium bisglycinate powder

Increasing magnesium-rich foods and taking certain types of magnesium supplements, particularly capsules, powder, or liquids containing magnesium citrate, magnesium sulfate, or magnesium hydroxide, may be helpful for some people with IBS.

Always follow the directions on the package to avoid problems and be sure to speak with a doctor if you’re considering magnesium as a treatment option for IBS-C.

Magnesium for IBS with constipation may not be a solution for long-term treatment. If you find that magnesium no longer helps treat IBS-C, see a doctor to discuss other treatment options.