Foundations

Electrolytes and Keto Flu 101

What the keto flu is, why low insulin makes you lose sodium and water, the sodium, potassium, and magnesium targets that prevent it, and the foods that get you there.

Built by Barron Hansen · Last updated June 2026

What the keto flu really is

The keto flu is the bundle of symptoms some people hit in the first week of cutting carbs: headache, fatigue, brain fog, irritability, muscle cramps, and a lightheaded feeling when you stand up. It can feel like the start of a head cold. It is not an infection, and it is not a sign that keto is wrong for you. It is an electrolyte problem, and electrolytes are the fix.

The good news is that it is largely preventable. People who load up on sodium and minerals from day one often skip the keto flu entirely. The ones who get hit hardest are usually eating clean, drinking lots of plain water, and getting almost no salt, which is exactly the combination that drains electrolytes fastest. Understanding why explains the whole fix.

Why low insulin makes you lose sodium and water

When you eat carbs, insulin rises. One of insulin's lesser-known jobs is telling your kidneys to hold on to sodium. Cut carbs, and insulin falls, and that signal reverses: your kidneys start excreting sodium instead of keeping it. Sodium pulls water along with it, so you lose both at once. This is the real engine behind the dramatic first-week weight drop.

There is a second source of water loss happening at the same time. Your body stores carbohydrate as glycogen in your muscles and liver, and every gram of glycogen is bound to three to four grams of water. As you burn through 400 to 500g of stored glycogen in the early days, the water it was holding is released too. Between the glycogen water and the sodium your kidneys are dumping, you can shed several pounds of fluid fast. The catch is that you lose potassium and magnesium in the rush as well, and that mineral shortfall is what produces the headaches, cramps, and fatigue.

The three minerals that matter, and your targets

Three electrolytes do the heavy lifting on keto. Sodium is the most important and the most neglected. On low carb you excrete far more of it, so most keto sources suggest aiming for roughly 3,000 to 5,000mg of sodium a day, which is well above standard advice. That is about 1.5 to 2.5 teaspoons of salt across the day, from salting your food, sipping broth, and adding a pinch to your water. If you have high blood pressure or kidney concerns, set your sodium target with your doctor rather than from a general guide.

Potassium works as sodium's partner, and a common target is in the range of 3,000 to 4,700mg a day, almost all of it reachable from food. Magnesium is the third, with most adults aiming for roughly 300 to 400mg a day. Magnesium is the one mineral genuinely hard to get from keto-friendly food in full amounts, which is why a supplement such as magnesium glycinate or citrate is a reasonable addition. To estimate your own numbers, the Electrolyte Calculator turns your weight and carb level into daily sodium, potassium, and magnesium targets.

Where to get them from food

Sodium is the easiest to fix: salt your food generously, drink a cup or two of bouillon or bone broth, and add a small pinch of salt to a glass of water if you feel foggy. For potassium, the standouts are avocado, which carries around 700mg in a medium fruit, plus leafy greens like spinach, along with salmon, mushrooms, and zucchini. For magnesium, lean on pumpkin seeds, spinach, almonds, dark chocolate that is 85 percent or higher, and mackerel.

You can find the exact mineral content of these staples in the keto food database. A practical daily habit covers most of it: eat an avocado, a big serving of leafy greens, and a fatty fish or a handful of seeds, then salt everything to taste. That combination, plus a magnesium supplement, gets the average person close to all three targets without much effort.

The first two weeks: a timeline

Days one and two usually feel fine, because you are running on the glycogen still in storage. Days three through five are the classic keto flu window, when glycogen is nearly gone, sodium loss is peaking, and symptoms show up if your electrolytes are low. This is exactly when staying ahead on salt and minerals pays off most. Drink to thirst here rather than forcing down plain water, since flooding water without sodium can wash out even more of it and make things worse.

By the end of week one most people feel noticeably better, and through the second week energy usually climbs as the body adapts to running on fat and ketones. For most people the rough patch is short, often two to five days and rarely beyond two weeks. If symptoms are severe, drag on much longer, or include a racing or irregular heartbeat, that is worth a conversation with a doctor, not something to push through. Once you are through it, a good next step is to confirm you are actually in ketosis, which the guide on how to test for ketosis walks through. New to all of this? The keto for beginners guide covers the rest of the starting line.

Frequently asked questions

This article is for general information only and is not medical advice. Keto is not right for everyone. If you are pregnant, take medication, or have a health condition, talk to your doctor before changing how you eat. See our medical disclaimer for more.

References

  1. Phinney SD, Volek JS. The Art and Science of Low Carbohydrate Living. Beyond Obesity LLC, 2011. Sodium and electrolyte guidance for a well-formulated ketogenic diet.
  2. Virta Health. Managing Potassium and Sodium as Part of a Well-Formulated Ketogenic Diet.
  3. National Institutes of Health, Office of Dietary Supplements. Magnesium Fact Sheet for Health Professionals.
  4. National Institutes of Health, Office of Dietary Supplements. Potassium Fact Sheet for Health Professionals.

Related