> For the complete documentation index, see [llms.txt](https://docs.foodcore.io/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.foodcore.io/costing-and-pricing-core/how-costing-works.md).

# How recipe costing works

{% hint style="info" %}
📦 Available on **FoodCore Core**. [Upgrade your plan](https://docs.foodcore.io/getting-started/essentials-vs-core.md) to access this feature.
{% endhint %}

The Cost Calculator isn't doing anything magical — it's doing the same arithmetic you'd do on a spreadsheet, just faster and with fewer mistakes. This article walks through exactly how FoodCore arrives at the numbers you see, so you can trust them and explain them to anyone who asks.

## Step 1: Convert pack price to cost per unit

Every ingredient in FoodCore has a pack size and a pack price. From those two values, FoodCore calculates a **cost per unit** — whether that unit is a gram, millilitre, item, or whatever unit of measure you've chosen.

**Example:** You buy a 500 g bag of ground almonds for £2.00.

> £2.00 ÷ 500 g = **£0.004 per gram**

That rate is stored and used every time the ingredient appears in a recipe.

## Step 2: Calculate each ingredient's line cost

For each ingredient line in the recipe, FoodCore multiplies the quantity used by the cost per unit.

**Example:** Your Victoria sponge recipe uses 200 g of ground almonds.

> 200 g × £0.004/g = **£0.80**

Every ingredient line in the recipe gets the same treatment.

## Step 3: Sum the ingredient lines into a batch cost

All the line costs are added together to give the **total ingredient cost for one batch** of the recipe.

If your Victoria sponge has six ingredients and their line costs sum to £2.60, your ingredient batch cost is £2.60.

## Step 4: Apply wastage

Wastage accounts for trim, spillage, failed batches, and the natural loss that happens in any real kitchen. You set a wastage percentage in the Cost Calculator, and FoodCore adds that proportion on top of your ingredient cost.

**Example:** 10% wastage on a £2.60 ingredient cost adds £0.26, bringing ingredient cost to **£2.86**.

## Step 5: Add the other cost lines

This is where the Cost Calculator goes beyond a basic recipe costing tool. You can add:

* **Labour** — enter an hourly rate and the number of hours the batch takes. FoodCore multiplies them.
* **Power** — an estimate of the electricity and gas cost for the batch.
* **Packaging** — the total cost of boxes, bags, labels, and any other packaging per batch.
* **Delivery** — courier costs, fuel, or platform fees if applicable.
* **Overheads** — your share of fixed costs (rent, insurance, subscriptions) allocated to this product.

Each of these is entered per batch and added to your running total.

## Step 6: Arrive at the total cost

**Total cost = ingredient cost (with wastage) + labour + power + packaging + delivery + overheads**

FoodCore divides the batch total by the number of units the batch makes to give you a **cost per unit**.

## Step 7: Calculate margin and markup

Once you've entered a selling price (or let FoodCore calculate one from a target margin), two key figures appear:

**Gross margin %** = (Selling price − Total cost) ÷ Selling price × 100

**Markup %** = (Selling price − Total cost) ÷ Total cost × 100

These are related but different. Margin is the percentage of the selling price that is profit. Markup is how much you've added on top of cost. Food businesses typically talk in margin terms, so that's the figure to focus on.

### Worked example

You make a celebration cake. Here's the full cost breakdown:

| Item                          | Cost       |
| ----------------------------- | ---------- |
| Ingredients (with 8% wastage) | £2.30      |
| Labour (1.5 hrs @ £12/hr)     | £18.00     |
| Packaging                     | £1.20      |
| Overheads (share)             | £0.50      |
| **Total cost**                | **£22.00** |

You sell the cake for £55.00.

> Gross margin = (£55.00 − £22.00) ÷ £55.00 × 100 = **60%** Markup = (£55.00 − £22.00) ÷ £22.00 × 100 = **150%**

A 60% gross margin gives you room to cover your fixed costs and generate a net profit. Whether that's enough depends on your overall business model, but at least you know exactly where you stand.

## What's next

* [Check your profit margin](https://docs.foodcore.io/costing-and-pricing-core/profit-margin.md)
* [Price your products](https://docs.foodcore.io/costing-and-pricing-core/pricing-products.md)
* [Update ingredient prices](https://github.com/CharliesGFTreats/foodcore-docs/blob/master/costing/update-price.md)
