Macro Calculator

Calculate protein, fat, and carbohydrate targets by calorie percentage or grams per kilogram. See the full calorie split in your browser.

Set your targets

kcal

Splits a calorie target you have already chosen

kg

Used for per-kilogram results and weight-based rules

%
%
%

Automatically calculated as 100% minus protein and fat

Lock protein and fat percentages, then assign the remaining calories to carbohydrates.

Example values are loaded. Adjust them or calculate now.

Daily macro targets
Planned calories 2,200 kcal
Protein 165 g 660 kcal · 30% · 2.36 g/kg
Fat 61 g 550 kcal · 25% · 0.87 g/kg
Carbohydrates 248 g 990 kcal · 45% · 3.54 g/kg
  1. Protein: 2,200 × 30% ÷ 4 = 165 g
  2. Fat: 2,200 × 25% ÷ 9 ≈ 61.1 g
  3. Carbohydrates: remaining 990 kcal ÷ 4 = 247.5 g

Calculations retain 0.1 g precision while summary cards show whole grams. Everyday food tracking does not need gram-perfect accuracy.

How to use the macro calculator

  1. Enter your targets — Enter a daily calorie target and body weight.
  2. Choose an allocation method — Use percentage mode or set protein and fat in grams per kilogram.
  3. Review the calculation — Calculate the targets, then review grams, calorie shares, and the displayed arithmetic.

Learn more

Formulas, example, and everyday use

The usual energy factors are 4 kcal per gram of protein, 4 kcal per gram of carbohydrate, and 9 kcal per gram of fat. Percentage mode multiplies calories by each percentage and divides by the energy factor. Weight mode calculates protein and fat from body weight, then uses the remaining calories for carbohydrates.

Example: 2,200 kcal, 70 kg, and 30% / 25% / 45% Protein is 2,200 × 30% ÷ 4 = 165 g; fat is about 2,200 × 25% ÷ 9 = 61.1 g; carbohydrates are 2,200 × 45% ÷ 4 = 247.5 g. You can split these approximate targets across meals and adjust them against food labels and actual portions.
Terms and common misconceptions
  • Macronutrients: nutrients needed in relatively large amounts; this tool handles protein, fat, and carbohydrates.
  • Calorie target: the total energy you plan to eat each day. This tool does not estimate basal metabolism or total daily energy expenditure.
  • g/kg: grams per kilogram of body weight, used to link body weight to protein or fat targets.

The result is a planning starting point, not a prescription that must be hit exactly every day. Rounded labels, cooking differences, and portion estimates introduce variation. Percentages also do not represent food volume because fat provides more energy per gram.

Scope and health information

This tool only performs an arithmetic split. It does not judge whether a calorie target or macro ratio is appropriate for you, and it does not replace advice from a doctor or registered dietitian. Pregnant or breastfeeding people, minors, competitive athletes, and people with kidney, liver, metabolic, or eating-related conditions should consult a qualified professional. The calculator stops if the protein and fat rules require more than the total calorie target.

Tool information, privacy, and sources

All calculations run locally in this browser. Weight, calories, and results are not uploaded, and no third-party scripts are used. The page does not automatically save your inputs; the one-time guide stores only that it has been shown.

Energy factors are informed by the FAO reference Food energy – methods of analysis and conversion factors and general nutrition reference ranges can be reviewed in the NCBI Bookshelf Dietary Reference Intakes summary table. These sources explain general concepts and do not evaluate your inputs.

Open-source research was completed on July 28, 2026. No third-party project or calculation library is used; the core algorithm is an independent native JavaScript implementation that can run offline.

Frequently asked questions

Does this calculator estimate my calorie needs?

No. You provide an existing daily calorie target; the calculator only divides that target among protein, fat, and carbohydrates.

Are the results medical or dietary advice?

No. The results are planning estimates. Individual needs can differ, especially during pregnancy, childhood, competitive training, or when a health condition affects nutrition.

Does the calculator upload or save my data?

Calculations stay in your browser and inputs are not uploaded. The page does not save your values; it only stores whether the one-time button guide has been shown.