> ## Documentation Index
> Fetch the complete documentation index at: https://docs.stockful.app/llms.txt
> Use this file to discover all available pages before exploring further.

# Bills of materials

> What a product is made of: components per unit made, unit conversion, versioning, and multi-level chains where one material is made from another.

A **bill of materials** says what one unit of a finished item takes. It is a recipe; the app calls it a bill of materials, so the docs do too.

Open **Bills of materials** from the Raw materials hub, then **Add bill of materials**.

* Under **Makes**, choose what it produces. Use **Add product** for a Shopify product, or **Add material** for a material you make rather than buy.
* Under **Components**, add what goes in, each with a quantity and a unit.
* **Production time** is optional, and sets the expected date when a batch starts.

## Quantities are per one unit made

One cookie takes 0.05 kg of flour, not the batch quantity. Stockful multiplies by the batch size when you start one, so a bill of materials stays correct at any volume.

## Units have to convert

A component's quantity is stated in whatever unit suits the recipe, then converted into the unit its material is stocked in.

Grams against a kilogram-stocked material converts, and 300 g lands as 0.3 kg. Litres against a kilogram-stocked material does not, because that needs a density Stockful has no way to know. It refuses the line rather than guessing.

Count units convert to themselves and nothing else, which is what you want: three wicks is three wicks.

## Versioning

Editing a bill of materials **supersedes** it rather than rewriting it. The old version stays, attached to every batch that used it, so a run from last month still shows what it actually consumed. Changing tomorrow's recipe never rewrites yesterday's history.

## Multi-level

A bill of materials can name another material as a component. A cookie is made of dough, and dough is made of flour.

Stockful walks the whole chain, at every point it matters:

* Starting a batch of cookies consumes flour, through the dough.
* Reordering flour accounts for the cookies you will sell, through the dough.
* **Dough you already hold reduces the flour you need.** Fifty kilograms of dough on the shelf is fifty you do not have to make, and the flour for it is not asked for.

<Note>
  A loop is refused. If A is made from B and B from A, Stockful reports it rather than following it round, and anything above the loop stops contributing until you fix it.
</Note>

## When something cannot be read

A bill of materials with an unconvertible unit or a missing material cannot be costed. Stockful quarantines that one rather than half-using it, since a partial answer would under-order everything else in the same recipe.

The reorder page marks affected materials and shows how many bills of materials could not be read, so it is visible rather than silent.
