Short answer: A keto macro calculator finds your calorie target first (Mifflin-St Jeor BMR × activity × goal), then fixes net carbs (usually 20–50 g), sets protein per kg and fills the rest with fat at 9 kcal/g. Example: a 30-year-old woman, 165 cm, 68 kg, lightly active, on a 20% cut: TDEE 1,925, target 1,540 kcal, 95 g protein, 25 g net carbs, 118 g fat.
General information, not medical advice. Check with a doctor or registered dietitian before a big diet change, especially if you have a medical condition, are pregnant, or have a history of disordered eating.
A keto macro calculator takes the calories you plan to eat and splits them into fat, protein and carbohydrate in the shape a ketogenic diet needs: very low carbohydrate, enough protein, and fat making up the rest. The calculator above works out the calories as well. You enter sex, age, height, weight, activity level and a goal (cut, maintain or bulk); it computes your BMR with Mifflin-St Jeor, multiplies by your activity factor to get TDEE, and applies the goal percentage to get a daily target. If you already have a number you trust, an optional field lets you type it in instead. It then works in grams rather than fixed percentages: protein in grams per kilogram (it starts at 1.4 g/kg), a net-carb cap (it starts at 25 g, adjustable up to 50 g), and every remaining calorie filled with fat, with the percentage each macro ends up as and every line of arithmetic shown. This page explains why that order makes sense, compares the familiar keto ratios such as 70/25/5, and works the arithmetic from a TDEE down to grams so the output is never a black box. You don't need to know your calorie target before you start: the tool calculates it, and your TDEE is the same on keto as on any other diet.
Keto Macro Calculator
Your TDEE, then net carbs fixed, protein per kg and fat filling the rest.
Units
Sex
Ketogenic diets usually keep carbs to roughly 20–50 g a day.
Leave blank to use the TDEE calculated above.
Calorie target, moderate cut
1,540 kcal/day
TDEE 1,925 kcal = BMR 1,400 × 1.375. Your TDEE is the same on keto as on any other diet.
Protein
95 g
25% kcal
Fat
118 g
69% kcal
Net carbs
25 g
6% kcal
Show the math
BMR (Mifflin-St Jeor) = 1,400; TDEE = 1,400 × 1.375 = 1,925; target = TDEE × 0.80 = 1,540 Protein = 68.0 kg × 1.4 = 95 g (381 kcal) Carbs = 25 g (100 kcal) Fat = (1,540 − 381 − 100) ÷ 9 = 118 g Check: 1,540 kcal (4 kcal/g protein and carbs, 9 kcal/g fat)
Bacon and eggs: a plate with no starchy side, so nearly all of its calories come from fat and protein, the split a keto macro target is built around. Photo: Ocdp, CC0.
What a keto macro calculator actually computes
Every macro calculator starts from the same place: a calorie number. On this site that number is your TDEE — total daily energy expenditure — and if you want the components behind it, the explainer on what is TDEE breaks down basal metabolic rate, the thermic effect of food, and movement. The keto calculator doesn't change how many calories you burn. It only decides what those calories are made of.
On a normal diet, macros negotiate freely. On keto they don't, because the entire point is to keep carbohydrate low enough that your liver runs short on glucose and starts producing ketone bodies from fat instead. That metabolic switch is fragile at the top end of carbohydrate intake, so keto flips the usual priority order. Carbs get a hard ceiling first. Protein gets set second, as grams per kilogram of body weight, so it tracks your size rather than a percentage of whatever calories you eat. Fat is the plug variable: whatever calories are left after carbs and protein are accounted for, fat fills. That's why fat percentages on keto look shocking (60–75% of calories) to anyone used to mainstream nutrition advice — it isn't that you're chasing fat, it's that fat is the only macro left with room to move once carbs are capped.
So the calculator's real work is three steps: fix net carbs in grams, set protein from your weight, and let fat absorb the remainder. The fat percentage is an output, not an input. Understanding that order is the difference between reading your macros as arbitrary and understanding why they're shaped the way they are.
Keto macro ratios side by side
Keto plans are often described as percentages of calories. These are the splits most commonly quoted, with the grams each gives at a 2,000-calorie reference (fat ÷ 9, protein and carbs ÷ 4). There is no single 'correct' keto ratio, and the calculator above does not force one: it lets you fix carbs and protein in grams and shows the percentages that result.
Approach
% Fat / % Protein / % Carbs
Fat (g)
Protein (g)
Carbs (g)
Standard ketogenic (often quoted)
70 / 25 / 5
156
125
25
Relaxed / "lazy" keto
65 / 25 / 10
144
125
50
High-protein keto
60 / 35 / 5
133
175
25
Very-low-carb induction
75 / 20 / 5
167
100
25
Classic 4:1 therapeutic (by weight)
90 / 6 / 4 (approx.)
200
30
20
Grams are calories × share ÷ 9 for fat and ÷ 4 for protein and carbs, rounded; the 4:1 row is 4 g of fat for every 1 g of protein plus carbohydrate. Percentages hide a problem: on a fixed share, protein grams move with calories, so a smaller eater on 25% protein can end up with far less protein per kilogram than a larger one. That is why the calculator sets protein per kilogram instead. The 4:1 ratio is a clinical diet used under medical supervision, not a body-composition plan.
Worked example: from TDEE to keto grams
Percentages are useless at the grocery store, because you eat grams, so the calculator's job is to land on grams. The conversion rests on the calorie density of each macro: fat carries 9 calories per gram, while protein and carbohydrate carry 4. Fat being more than twice as energy-dense is why a large fat percentage still fits into a normal-sized day of food.
Take an 1,800 kcal target typed into the tool's optional calorie field, 68 kg body weight, protein at 1.4 g/kg and 25 g of net carbs. (With no number typed in, the tool's opening profile, a lightly active 30-year-old woman at 165 cm and 68 kg on a 20% cut, computes a target of 1,540 kcal instead: same 95 g protein and 25 g carbs, and fat drops to (1,540 − 381 − 100) ÷ 9 ≈ 118 g.)
Protein: 68 × 1.4 = 95.2, about 95 g, which is 381 kcal.
Carbohydrate: 25 g × 4 = 100 kcal.
Fat: (1,800 − 381 − 100) ÷ 9 = 1,319 ÷ 9 = 146.6, about 147 g.
Check by multiplying back: 95 × 4 + 25 × 4 + 147 × 9 = 380 + 100 + 1,323 = 1,803 kcal, on target within rounding. The resulting split is 21% protein, 73% fat and 6% carbohydrate, which looks like a classic keto ratio even though no ratio was typed in.
Now compare a percentage approach for the same person at 2,000 kcal on 70/25/5: fat = 1,400 ÷ 9 = 156 g, protein = 500 ÷ 4 = 125 g, carbs = 100 ÷ 4 = 25 g. At 2,400 kcal the same ratio gives 187 g fat, 150 g protein and 30 g carbs. On the gram approach, protein for this 68 kg person stays at 95 g (or whatever g/kg you choose) at every calorie level, and only fat changes. If you prefer a body-weight protein anchor with carbs filling the gap for a non-keto diet, the general macro calculator does that version.
Protein is the macro people get wrong on keto
Fat and carbs are the loud numbers on keto, but protein is where many plans quietly go wrong, in both directions. A long-standing worry is that too much protein will 'kick you out of ketosis' because the liver can turn amino acids into glucose (gluconeogenesis). That worry pushes some people to eat very little protein, which is the riskier error when most keto dieters are also in a calorie deficit and want to keep muscle.
The calculator's protein field runs from 0.8 g/kg, the adult RDA, up to 3.1 g/kg, and starts at 1.4 g/kg. That default is the bottom of the 1.4–2.0 g/kg range the International Society of Sports Nutrition gives for most people who exercise (Jäger et al. 2017). If you lift regularly, moving toward the middle or top of that range is reasonable; in the gram approach that simply takes calories from fat, because carbs are already fixed. Keeping carbs capped, protein set from body weight and fat as the variable is the most useful habit on keto, and it is the one a percentage-only view of macros tends to hide. If you have kidney disease or another condition affected by protein intake, check the target with your doctor.
Worked example
Worked example: why fat is a lever, not a number to minimize
Sex
Male
Age
45
Height
183 cm
Weight
95 kg
Activity
Moderately active (×1.55)
Goal
Moderate cut (−20%)
Keto settings
1.6 g/kg protein, 25 g net carbs
This illustrative man lifts three or four times a week. Mifflin-St Jeor BMR = 10 × 95 + 6.25 × 183 − 5 × 45 + 5 = 950 + 1,143.75 − 225 + 5 = 1,873.75, rounded to 1,874 kcal. TDEE = 1,873.75 × 1.55 = 2,904 kcal. A moderate cut of 20% gives 2,904 × 0.80 = 2,323 kcal, which is the number he types into the keto calculator.
With protein at 1.6 g/kg: 95 × 1.6 = 152 g, or 608 kcal. Net carbs at 25 g are 100 kcal. Fat fills the rest: (2,323 − 608 − 100) ÷ 9 = 1,615 ÷ 9 = 179 g. As shares of calories that is about 26% protein, 70% fat and 4% carbohydrate.
The lesson is what happens if fat is treated as something to keep low. Suppose he hits the protein and carb numbers but cooks lean and stops at 90 g of fat. His day is then 608 + 100 + 90 × 9 = 1,518 kcal: 805 kcal under his cut target and about 48% below his estimated TDEE. That is no longer the planned 20% cut; it is a much deeper deficit than intended, which tends to be harder to sustain. On a keto plan, fat is the macro that makes the calorie target add up, so the gram figure for fat matters as much as the carb cap.
These figures are what the formulas give for this example; real intake and weight change need to be checked against a 2–3 week weight trend.
An illustrative person, not a real case. Every number is computed with the formulas on this page.
Total carbs vs net carbs: which does the calculator cap?
The carb line hides a definitional choice that trips up nearly everyone new to keto. 'Total carbs' is every gram of carbohydrate on the label. 'Net carbs' subtracts fiber and, in the US, sugar alcohols, on the reasoning that fiber isn't digested into glucose and therefore doesn't meaningfully raise blood sugar or interrupt ketosis. So a food showing 12 g total carbs and 8 g fiber has 4 g net carbs. Which number you track changes how much food fits under your cap by a lot.
Most keto dieters count net carbs, and for whole-food eating that's reasonable — the fiber in broccoli or avocado genuinely behaves differently from the sugar in a soda. The catch is processed 'keto' products that lean on sugar alcohols and fiber-fortified additives to advertise low net carbs; not every sugar alcohol or added fiber behaves like the fiber in vegetables, so the net-carb figure on those labels can flatter the product. A cautious rule: count net carbs from whole foods, but count total carbs from processed keto-branded packages. Whichever convention you pick, be consistent — a 25-gram cap means something completely different in total-carb terms than in net-carb terms, and switching between them mid-week is how people wonder why they fell out of ketosis while 'staying under 25.' The calculator above labels its carb field as net carbs; if you track total carbs instead, enter your total-carb cap in the same field and read the result the same way.
“Fix the carbs, set protein from your body weight, and let fat fill whatever calories are left. Everything a keto macro calculator does is those three moves in that order.”
Common keto macro mistakes
Patterns that commonly derail otherwise reasonable keto plans:
Eating low-carb but not high-fat. Cutting carbs while keeping protein high and fat low isn't keto — it's an under-fueled low-carb diet that leaves you flat and hungry. Fat has to rise to fill the calorie gap.
Ignoring calories entirely. Keto blunts appetite for many people, but it does not repeal energy balance. If you eat above your TDEE in fat, you still gain. The macro split decides fuel type; total calories still decide the direction of the scale.
Setting protein very low out of gluconeogenesis fear. Under-eating protein during a deficit is the more common real-world problem; the 1.4–2.0 g/kg range for people who exercise is a sensible place to start.
Confusing total and net carbs, then switching between them. Pick one convention and hold it, and be skeptical of net-carb claims on processed keto products.
Neglecting electrolytes. Very low carbohydrate intake is often accompanied by early water loss, and the headaches, fatigue and cramps people call 'keto flu' in the first week are commonly linked to fluid and electrolyte shifts. Ask a doctor before changing salt or mineral intake if you take blood-pressure or kidney medication.
Reading the week-one scale drop as fat loss. Early weight loss on low-carb diets includes water. Judge real progress by the weekly-average trend after week two, exactly as on any diet.
Dialing in your macros after the calculator gives you numbers
The calculator hands you a starting point, not a verdict. Every TDEE equation is an estimate for a population, not a measurement of you: it can't see your exact muscle mass or how much you actually move, so your real maintenance may sit above or below it. You confirm it the same way regardless of diet: eat at the target for two to three weeks, track the weekly-average weight trend, and adjust by 100–150 calories based on what the scale actually did — then re-run the same ratio against the new calorie number.
If fat loss is the goal, you'll want your calorie target below maintenance before you ever split it into macros. The keto ratio doesn't create a deficit; it only shapes one. Pick a cut in the keto calculator's goal menu (−10%, −20% or −25% of TDEE), or set the deficit with the calorie deficit calculator and type that number into the optional calorie field. The reasoning on turning a maintenance figure into a sustainable deficit is in the guide to using TDEE for weight loss, and the mechanics are identical to any diet — keto just changes the foods, not the arithmetic. One keto-specific note while you tune: if you're holding protein at a fixed gram target for muscle protection and adjusting calories, do the adjusting in fat, since fat is your plug variable and carbs are already pinned to the floor. Keep protein steady, keep carbs capped, move fat up or down to steer the calories. That's the whole maintenance loop, and it's boring on purpose — boring is what's sustainable.
Does keto still require a calorie deficit to lose weight?
Yes. Keto often reduces appetite, which makes eating fewer calories easier, but it doesn't override energy balance. If you eat above your TDEE — even entirely in fat — you'll gain. Set your calorie deficit first, then split those calories into keto macros. The ratio decides fuel type; total calories decide direction.
Why is the fat number on keto so high?
Because fat is the plug variable. Keto caps carbs hard and sets protein to a moderate band, so fat is the only macro left to fill the remaining calories. It also helps that fat carries 9 calories per gram versus 4 for protein and carbs, so a large-looking fat percentage still fits into a normal-sized day of food.
Will too much protein kick me out of ketosis?
Not usually from the amounts most plans use. The worry is that the liver can turn protein into glucose, but cutting protein very low to avoid this leaves you short of the protein that helps keep muscle during a deficit, which is the more common problem. A moderate setting such as the calculator's 1.4 g/kg default, or up to about 2.0 g/kg if you train, is a reasonable range; if you measure ketones and see a change, adjust from there.
Should I count total carbs or net carbs?
Most people count net carbs (total carbs minus fiber, and in the US minus sugar alcohols) because fiber isn't digested into glucose. Net carbs work well for whole foods. Be more skeptical with processed 'keto' products that use sugar alcohols to advertise low net carbs — for those, counting total carbs is safer. Whichever you pick, stay consistent.
The most commonly quoted default is 70% of calories from fat, 25% from protein and 5% from carbohydrate, written 70/25/5. At 2,000 calories that is about 156 g fat, 125 g protein and 25 g carbs. The calculator above does not force a ratio: it fixes net carbs (default 25 g) and protein per kg (default 1.4 g/kg), and fat fills the rest, so the ratio is an output that usually lands close to 70/25/5.
How do I convert keto percentages into grams?+
Multiply your total calories by each macro's percentage, then divide by that macro's calories per gram: fat is 9 calories per gram, protein and carbs are 4 each. Example at 2,000 calories on 70/25/5: fat = 1,400 ÷ 9 ≈ 156 g, protein = 500 ÷ 4 = 125 g, carbs = 100 ÷ 4 = 25 g. The calculator works the other way: it starts from grams of protein and carbs and gives you the percentages.