Snooze University

Does the Ketogenic Diet Cause Insomnia? (Study Summary)

by Dale Cudmore | Updated: Nov 20, 2022

Most studies focus on the weight loss aspect of low carb diets, but not as much on the short term side effects.

When we take a closer look, there’s quite a bit of evidence showing that the ketogenic diet leads to short-term insomnia for many people.

We’ll look through the relevant research in this post, but basically sleep quality gets increasingly worse throughout the first month on average, but eventually gets better than it started in the first place.

Note that most of the improvement in sleep in the long term from keto is likely from losing weight, since obesity is a major insomnia risk factor (and sleep apnea).

Known Side Effects of a Keto Diet (The Keto “Flu”)

Going on a keto diet from a typical diet is a big shift for your body and gut microbiota, which results in most people experiencing keto flu symptoms.

This is a documented side effect, and often includes symptoms like (1):

  1. Nausea
  2. Vomiting
  3. Headache
  4. Fatigue
  5. Dizziness
  6. Insomnia

Some of those are likely interrelated to each other.

The bigger the change from the previous diet, the greater the typical severity of symptoms is likely to be.

SummaryInsomnia is a known side effect of switching to a ketogenic diet, and is one of the most common symptoms of the keto flu. Slowly transitioning to a keto diet by increasing fat levels progressively can lessen the severity of symptoms.

The Effect of a Ketogenic Diet on Sleep Quality

The best study that specifically analyzed sleep combined the data from 2 previous studies on the effects of switching to a low carb diet (2).

Subjects filled out the 56 item Atkins Health Indicator Test (AHIT) to self-report symptoms. They either switched to a low carb ketogenic diet (LCKD) or low fat diet (LFD).

While the picture is a bit small, you can see the severity of keto insomnia symptoms increased progressively from baseline for the first 4 weeks of the diet (the top line of hollow circles).

However, after that 4 week check-in, symptoms decreased to just above baseline during the week 6 and 8 check-in, and then dropped below baseline for the remaining measurements (up to 24 weeks).

Fatigue and hunger also dropped over time (moreso in the keto group than the low fat group).

Important note: Patients in the LCKD (keto) group also took a nutritional supplement, which may affect the results. In general vitamins don’t have much of an effect on insomnia, but we can’t say for sure in this specific situation.

SummaryCurrently, the best research available shows that switching to a keto diet typically results in worse sleep for up to 4 weeks, before eventually leading to better sleep in the long run. The effects will depend on how big of a transition the diet switch is for someone, along with their weight and general health.

The Effect of a Ketogenic Diet in Other At-Risk Groups

The above research we looked at was in relatively healthy, but overweight adults.

When there’s not a ton of research on a specific population, it can be useful to look at other groups that have been studied as well to get an idea if the conclusion is relatively similar.

I found 3 other studies that fit this category:

  • A keto diet in advanced cancer patients improved emotional functioning and reduced sleep disorder symptoms after 6 weeks (3).
  • A study of adolescents with morbid obesity found that a ketogenic diet reduced sleep abnormalities, mostly tied to the degree of weight loss (4).
  • A small study on narcoleptic patients found that a high fat diet was able to decrease fatigue, and also resulted in a short term increase in insomnia (5).

Overall, the results are very much aligned with what we saw before. If a keto diet can help someone lose weight, it will likely improve poor sleep.

Why Might a Ketogenic Diet Cause Sleep Problems?

Most people’s bodies are not used to being in a state of ketosis (i.e. running off of fats for energy).

This state causes changes in hormone levels as the body adjusts, which can affect you in several ways, often negatively at first. Some of these can interact directly with sleep (e.g. sleep hormone levels of melatonin and serotonin can be affected).

The 3 main reasons that a keto diet could lead to sleep disturbances are:

  • More urination at night - Most people report urinating more on a keto diet, which can lead to frequent trips needed in the middle of the night. There are a few speculated reasons, including increased water being released from glycogen as your body uses up those carbohydrate stores. Additionally, insulin levels typically lower, which reduces the amount of water your kidneys retain. 
  • Sugar “withdrawal” - If you are used to eating a lot of sugar, your body has a more difficult time entering into ketosis. Since your brain relies on glucose for energy, it doesn’t always function perfectly as your body gets used to creating and using limited stores of glucose effectively.
  • Low levels of electrolytes - Ketogenic diets are often low in certain nutrients if you’re not careful, especially magnesium and potassium. These are both vital for good quality sleep (and avoiding muscle cramps). In addition, low sodium levels lead to increased norepinephrine (an adrenaline hormone) that can make it harder to fall asleep (6).

For certain people, especially those with diabetes, there’s also a concern of hypoglycemia. This is a very dangerous condition where blood sugar levels drop below 70 mg/dl while sleeping at night. It typically causes you to wake up. Hypoglycemia shouldn’t occur for the vast majority of people trying a keto diet, but those with diabetes should consult their doctor first as they may be at increased risk.

Summary: Keto Diets and Insomnia

While the research is a bit limited, there does seem to be a consistent link between insomnia and starting a ketogenic diet.

While symptoms will vary individually, keto insomnia symptoms appear to peak around week 4 after the transition. A large calorie deficit can worsen sleep troubles.

Sleep quality then improves and eventually improves past baseline levels on average after about 3 months. A big part of that improvement is likely from subjects losing weight since they are usually overweight to begin with in the studies we looked at.

One final note I would draw attention to is that the subjects in all these studies had some significant health issues. They were supervised by medical staff the whole time, and anyone that is thinking about making a drastic diet change should have their health monitored by a doctor during the transition.

Sleep disorders can have severe effects on health, so it's important to monitor them closely with professional supervision, and resolve them as quickly as possible. It's worth improving sleep hygiene to minimize any sleep problems.


  1. Ketogenic Diet
  2. The Effects of a Low-Carbohydrate Ketogenic Diet and a Low-Fat Diet on Mood, Hunger, and Other Self-Reported Symptoms
  3. Effects of a ketogenic diet on the quality of life in 16 patients with advanced cancer
  4. The effects of a high-protein, low-fat, ketogenic diet on adolescents with morbid obesity
  5. Diet therapy for narcolepsy
  6. Evidence for increased renal norepinephrine overflow during sodium restriction in humans

Medical Disclaimer: The information on is not intended to be a substitute for physician or other qualified care. We simply aim to inform people struggling with sleep issues about the nature of their condition and/or prescribed treatment.

About the authorDale is the founder of Snooze University and a sleep researcher. I overcame my sleep issues and now I'd like to help you do the same by summarizing the latest sleep studies for you.