← Back to blog
How we calculate the macros of cooked recipes — under the hood
Dev log · July 11, 2026 · 4 min read

How we calculate the macros of cooked recipes — under the hood

How NutriApp counts calories and macros for multi-ingredient dishes — borscht, salad, okroshka. Why weight changes during cooking, where the oil hides, and an honest take on accuracy. No marketing gloss.

A single product is easy to count: open the database, set the grams, done. But what about borscht, a salad, or okroshka, where there are ten ingredients? Today — how that works under our hood. No marketing gloss: where everything is counted honestly, and where it stays an estimate.

Why this matters

Home cooking is the biggest hole in any calorie tracker. Dumplings, a casserole, a soup, or a salad can't be "found in the database" as one entry: each has its own composition and proportions. People either give up counting such dishes, or enter "something roughly similar" from someone else's recipe — and the numbers drift by hundreds of calories.

The goal is to let you count your dish once, from your ingredients, and then log a serving of it with one tap — without rebuilding it every time.

The base principle

A cooked dish is the sum of its ingredients. We take each product by its macros, add them up for the whole pot or salad bowl, and then divide by the number of servings.

Count a borscht recipe for 6 servings once, and the app knows the macros of a single bowl. From then on, it's not "borscht in general" that goes into your diary, but your borscht, at your serving size. That's what separates counting a recipe from "grabbing the closest thing in the catalog."

The main trap — weight changes during cooking

Here lies the mistake that makes home-cooked dishes get counted wrong most often.

When boiled, grains, pasta, and legumes absorb water and become 2-3× heavier. Meat, on the contrary, loses moisture and "shrinks" by 20-30%. So the macros per 100 g of a cooked dish ≠ the macros per 100 g of raw ingredients. Count 100 g of dry buckwheat as 100 g of cooked porridge, and you'll be off by a factor of three.

We count by the raw ingredients and the total yield of the dish. You specify what you cooked and how much, and into how many servings you divide it — and the system doesn't try to guess "how much boiled off." That way the numbers don't drift based on how long you simmered the soup.

Oil and dressings — the most common invisible add-on

A tablespoon of vegetable oil in the pan is ~90-120 kcal, and almost all of it soaks into the food. Fry vegetables "by eye," dress a salad "generously," and a side that's light on paper is suddenly higher in calories than buckwheat with chicken.

That's why in a recipe, oil and dressing are a separate line with grams, not "just a little." It's fats during cooking that most often turn a "healthy dish" into a hidden overshoot.

How it looks in the app

You build a dish from products with grams → you get the macros of the whole pot and of one serving → you save it as a recipe. From then on it behaves like a template: a bowl of soup or a portion of salad goes into the diary with one tap, no recalculating. Ate more or less? Change the number of servings and everything recalculates itself.

An honest take on accuracy

You can't count home cooking perfectly, and we don't pretend we can:

  • The dish's yield is an estimate. Exactly how much boiled off and into how many "real" servings the pot stretched depends on the stove, the lid, and the time. We give a reasonable model, not an absolute.
  • "By eye" breaks any calculation. If oil, salt, sugar, and dressings go in without measuring, accuracy is limited by that, not by our formulas.
  • We don't model digestibility. We count by standard energy values, without corrections for individual digestion — for calorie tracking that's enough.

But a simple rule applies here: "roughly right, every day" beats "perfect, but never." What matters isn't the fifth decimal place, but a stable habit of counting — and recipes remove the main reason to abandon it.

Where we're headed

  • Ready-made recipes for popular dishes in the database — borscht, pilaf, okroshka with a typical composition you can take as a base and tweak to your own.
  • Automatic yield estimation — suggesting the likely weight of the cooked dish from its composition, so you don't count it by hand.
  • A link with photo mode — the model sees "borscht," and we pull the typical recipe and fit the grams to the volume on the plate.

If you're curious — open NutriApp. And what's hardest for you to count — soups, baking, sauces? Write it in the VK discussion, and we'll break it down in upcoming posts.

Count calories automatically in NutriApp

Open NutriApp