What this tool does
Calories come from the same Mifflin-St Jeor TDEE engine and your fat-loss, maintain, or gain goal. Protein uses the deficit band when cutting and the muscle band otherwise. Carbohydrate is a hard gram cap. Fat fills whatever calories remain. If fat calories would go negative, the plan is incoherent — raise calories or lower protein/carbs.
How it works
Ketogenic diets used in clinics and trials usually keep carbs very low and fat high; protein is moderate, not unlimited. This tool will not check ketones, electrolytes, or fiber. Endurance quality often drops until you adapt — or until you admit you wanted a moderate-carb cut instead.
Formula and methodology
Calories = calorieTarget(TDEE, goal) with educational floor. Protein g ≈ midpoint of 1.8–2.4 g/kg if losing, else 1.6–2.2 g/kg. Carb kcal = carbCap × 4. Fat g = max(calories − protein×4 − carbCap×4, 0) / 9. Ketosis depends on glycogen, total carb, and person; macros cannot certify it.
How to interpret the result
If fat grams look enormous, that is the math of a high calorie budget plus a 25 g cap. If you feel wrecked lifting, keto is optional, not required for hypertrophy. Medical keto (epilepsy, etc.) is a supervised protocol this page is not.
Example
80 kg man, TDEE ~2,760, fat-loss calories ~2,210, carb cap 30 g, protein ~176 g midpoint of deficit band: protein kcal ~700, carb kcal 120, fat ≈ (2,210 − 820) / 9 ≈ 154 g. That is a high-fat pattern. Vegetables still count toward the 30 g.
Common mistakes
- Eating “keto” cookies that blow the cap.
- Protein so high that you never approach ketosis and calling it a failure of will.
- Ignoring sodium, potassium, and magnesium in the first weeks.
- Using keto to hide a disordered restriction of food groups.
When this estimate may be off
- You are on SGLT2 inhibitors or other drugs with ketoacidosis risk — this is a clinical stop, not a macro tweak.
- Pancreatic, gallbladder, or lipid disorders under specialist care.
- Pregnancy or eating-disorder history.
- Carb cap entered as net carbs while you eat a pile of sugar alcohols.
