Skip to content
Fit.Archive
English
Open my log

Food and nutrition

Macro Calculator: How to Calculate Your Macros (Protein, Carbs, Fat) With Worked Examples

Photo: a woman in a dark home kitchen spoons cooked rice onto a plate that sits on a kitchen scale, next to a plate of greens and chicken

To calculate your macros, set calories first and split them in 4 steps: (1) find your daily calorie target from your TDEE and goal, (2) set protein by body weight, about 1.6–2.2 g per kg, (3) set fat at about 25% of calories, (4) give all remaining calories to carbs. Protein and carbs have 4 kcal per gram, fat 9. Example: a 25-year-old man, 170 cm, 65 kg, lifting 4 times a week, maintaining at 2,468 kcal gets 130 g protein, 69 g fat and 332 g carbs.

A macro calculator does exactly this arithmetic. Below are the formulas, why each number is where it is, and six worked examples you can copy. The examples use the same rules as FitArchive’s “Nutrition targets” calculator, so you can check the app’s result by hand.

Step 1: set your calories

Macros are a split of a calorie number, so the calorie number comes first. Work out your TDEE (the calories that keep your weight steady) from weight, height, age and activity, then subtract for a cut or add for a bulk. The full method, with the Mifflin-St Jeor and Katch-McArdle formulas, is in how to calculate TDEE. In short:

Step 2: set protein by body weight, not by percentage

Protein is the macro that most affects how much of the weight you gain or lose is muscle, so set it first, in grams per kilogram of body weight:

SituationProtein per dayEvidence
Lifting, maintaining or bulking1.6–2.0 g/kgA 2018 meta-analysis of 49 trials (1,863 people) found no further gain in fat-free mass above about 1.6 g/kg. The ISSN position stand gives 1.4–2.0 g/kg for most people who exercise.
Lifting while cuttingHigher, up to 2.3–3.1 g/kgThe ISSN says 2.3–3.1 g/kg of body weight may be needed to keep lean mass in a calorie deficit. A 2014 review for natural bodybuilders recommends 2.3–3.1 g/kg of lean mass, which is a lower number for most people.

FitArchive’s calculator uses 2.0 g/kg when you maintain or bulk and 2.2 g/kg when you cut. If you enter your body fat, it caps protein at 2.6 g (2.8 on a cut) per kg of lean mass; without body fat and with a BMI over 30, it uses the weight that would give a BMI of 25 at your height instead of your full weight. Both caps only ever lower the number, so people with more body fat don’t get a protein target they can’t eat.

Why not a percentage? A “30% protein” split gives 113 g at 1,500 kcal but 225 g at 3,000 kcal, while your muscles’ needs follow your body size, not your calories. More on daily amounts and meal timing in how much protein per day to build muscle.

Step 3: set fat as a share of calories

Fat is usually set as a share of calories:

FitArchive’s calculator sets fat at 25% of calories, with a floor of 0.6 g per kg of body weight so a low calorie target never pushes fat very low. For most people the 25% rule is the bigger of the two: at 2,000 kcal, 25% is 56 g, which only falls below the floor for someone heavier than about 93 kg.

Fat (g) = calories × 0.25 ÷ 9

Step 4: give the rest to carbs

Carbs fill whatever is left after protein and fat:

Carbs (g) = (calories − protein g × 4 − fat g × 9) ÷ 4

Carbs fuel hard training, so for lifters they usually end up the largest macro by weight. If you prefer more fat and fewer carbs, you can trade them at 1 g fat for about 2.25 g carbs (9 kcal vs 4 kcal) without changing calories.

Worked examples: macros to cut, maintain and bulk

All six use the 4 steps above and are rounded to whole grams, so the macros add up to within about 2 kcal of the calorie target.

GoalProteinFatCarbs
A, maintain 2,468 kcal130 g69 g332 g
A, cut 0.5% a week 2,111 kcal143 g59 g252 g
A, bulk 0.25% a week 2,647 kcal130 g74 g365 g
B, maintain 1,700 kcal110 g47 g209 g
B, cut 0.25% a week 1,549 kcal121 g43 g170 g
C, cut 0.5% a week 2,098 kcal167 g58 g227 g

Example A, maintain, step by step:

  1. Calories: TDEE = 1,592.5 (Mifflin-St Jeor BMR) × 1.55 = 2,468 kcal.
  2. Protein: 65 kg × 2.0 = 130 g (520 kcal).
  3. Fat: 2,468 × 0.25 ÷ 9 = 68.6, so 69 g (621 kcal).
  4. Carbs: (2,468 − 520 − 621) ÷ 4 = 331.75, so 332 g.

As shares of calories, that is about 21% protein, 25% fat and 54% carbs.

Example B on a faster cut. For the woman in example B, a 0.5% weekly cut works out to about 1,398 kcal. FitArchive’s calculator does not go below 1,500 kcal or below your BMR (and never above your TDEE), so it gives her 1,500 kcal with 121 g protein, 42 g fat and 160 g carbs. In practice she will lose a bit more slowly than 0.5% a week. That is deliberate: very low targets make enough protein and micronutrients hard to eat.

Example C with body fat. With 30% body fat, his lean mass is 59.5 kg, so BMR comes from Katch-McArdle (TDEE 2,566 kcal). On a cut, 2.2 g × 85 kg would be 187 g of protein, but the lean-mass cap (59.5 × 2.8) lowers it to 167 g. The cut target is 2,566 − 468 = 2,098 kcal.

Overhead view of a day of high-protein meals on a dark slate table: Greek yogurt, two fried eggs, grilled chicken over rice, cubed tofu, a glass of milk and a phone lying face down

To turn these grams into meals, see the high-protein foods list, cheap high-protein foods or, for Vietnamese dishes, Vietnamese food calories and protein.

Which macros matter most?

Not all four numbers need the same care:

  1. Calories decide whether your weight goes down, stays or goes up.
  2. Protein decides how much of that change is muscle. Try to hit it most days.
  3. Fat and carbs can move around from day to day as long as calories stay on target and fat doesn’t sit very low for long.

So if tracking every macro feels like too much, track calories and protein first.

Check your macros after 2–3 weeks

A calculator gives a starting point based on averages. Log your food and weigh yourself in the morning at least 3–4 times a week, then compare weekly averages after 2–3 weeks. If weight is moving at the rate you chose, keep the macros. If not, change calories by about 100–200 kcal a day, and take the change from carbs or fat, not protein. How to keep muscle while cutting covers what else to keep steady in a deficit.

Calculate and track macros in FitArchive

FitArchive is an app for logging workouts and meals. Its “Nutrition targets” screen calculates calories, protein, fat and carbs with the steps in this article. You can edit any target before saving. When you log a food, you can type only the macros and the calories fill in for you (4 kcal per gram of protein and carbs, 9 per gram of fat). Calculating targets and logging food and weight are free, including on the web app. On iPhone and Android, Plus adds adaptive targets that suggest a small calorie and macro adjustment from your logged food and weight trend, which you choose to apply or not. Looking for an app? See the best free calorie counter apps, or try the web demo.

This is general information, not personal nutrition or medical advice. If you are pregnant, breastfeeding, under 18, have kidney disease or another medical condition, or a history of eating disorders, ask a doctor or dietitian before changing your diet or eating in a calorie deficit.

FAQ

What is the best macro ratio for losing fat? There is no single best ratio. Keep calories in a deficit, protein high (FitArchive’s default on a cut is 2.2 g/kg of body weight), fat around 20–30% of calories, and carbs from the rest. The calorie deficit drives fat loss; the protein helps you keep muscle.

Is 40/30/30 a good macro split? It can work, but a fixed percentage ties protein to calories. On a small target it may give too little protein, and on a large one far more than you need. Setting protein in grams per kg first is more reliable.

How do I calculate macros for muscle gain? Eat enough above TDEE to gain 0.25–0.5% of body weight a week, set protein at about 1.6–2.0 g/kg, fat at about 25% of calories, and give the rest to carbs. Example A above gains at 2,647 kcal with 130 g protein, 74 g fat and 365 g carbs.

Do I need to hit my macros exactly? No. Getting close most days is enough. Aim to hit calories and protein, and let fat and carbs vary.

How many calories are in a gram of protein, carbs and fat? Protein 4 kcal, carbs 4 kcal and fat 9 kcal per gram. So 100 g of carbs is 400 kcal and 50 g of fat is 450 kcal.

All articles