Calculate macro

Convert protein, carbohydrate, and remaining fat percentages into approximate whole grams for one calorie target.

freeworks offlinenothing uploaded
ToolMacro Calculator
Input
Output
Put this on your own site

The frame below runs the same code as this page, in the reader's own browser. Nothing is sent to us, and nothing is sent to you.

Pick a dark background and the text and panels follow it, so the frame stays readable on a dark page.

Preview

How it works

Protein and carbohydrate receive their entered shares of daily calories, and fat receives the exact percentage left to reach 100. General Atwater factors divide those energy shares by 4 kcal per gram for protein and carbohydrate and 9 kcal per gram for fat before grams are rounded.

Formula
protein grams = calories × protein percentage ÷ 100 ÷ 4
fat grams = calories × remaining percentage ÷ 100 ÷ 9
  • Protein and carbohydrate have no defaults because a suitable split depends on the diet and clinical setting.
  • Using fat as the remainder prevents three independently entered percentages from drifting away from 100%.

Worked example

A balanced 2000 calorie day
30% protein, 40% carbohydrate, 30% fat
Input
											Calories: 2000
Protein percent: 30
Carb percent: 40
										
Output
												Protein grams: 150
Carb grams: 200
Fat grams: 67
Fat percent: 30
Protein calories: 600
Carb calories: 800
Fat calories: 600
											

When to use this

Nutrition-label reviews, meal-preparation plans, and sports diet plans translate an energy target into approximate gram amounts before particular foods are chosen.

Edge cases

  • Protein plus carbohydrate above 100% is rejected because it would require a negative fat allocation.
  • Whole-gram rounding can make 4 × protein grams + 4 × carbohydrate grams + 9 × fat grams differ slightly from the original calorie target.
  • Alcohol, fibre, sugar alcohols, and organic acids are outside this three-macronutrient allocation and may change energy shown on a food label.

References