Skip to main content

Unit Conversions

Unit conversions define how ordered products are converted into ingredient stock, and how quantities entered in packaging units are translated to the ingredient’s base unit throughout the app. They are used when Mathership receives orders, updates inventory through stock counts, transfers, or waste, calculates stock balances, creates inventory ledger entries, and calculates inventory value.

Convert products

Turn ordered vendor products into ingredient stock quantities.

Use packaging units

Enter quantities in boxes, bags, cases, bottles, or base units.

Keep stock consistent

Store all inventory movements in the ingredient’s base unit.

What unit conversions are used for

Use unit conversions when a product is ordered in one unit but inventory is tracked in another unit. Common examples:
  • A vendor product is ordered as a box but stock is tracked in kilograms
  • Milk is ordered in packs but inventory is tracked in liters
  • Bottles are ordered as cases but stock is tracked as single bottles
  • A recipe uses grams but the ingredient is stored in kilograms
  • POS sales reduce stock in smaller units than the purchasing unit

Where unit conversions appear in the UI

Unit conversion is not a standalone page. It is built into every screen where quantities are entered or displayed.

How unit conversions work

Mathership separates three concepts:

Example

If you receive 2 boxes of tomatoes and one box equals 10 kg, Mathership creates a receipt of 20 kg.

Base units

Each ingredient has a base unit. The base unit is the main unit used for inventory balances, ledger entries, reports, and recipe usage.
Choose ingredient base units carefully. Inventory movements, reports, recipes, and cost calculations depend on the base unit.

Standard unit conversions

Mathership recognises standard weight and volume units and can automatically convert between them.

Weight units

Volume units

These conversions are used automatically when the bottom packaging level’s unit differs from the ingredient’s base unit. For example, if the bottom level is in grams and the base unit is kilograms, Mathership multiplies by 0.001 automatically.

Product-to-ingredient conversion

Unit conversion is configured through product-to-ingredient mapping. A product mapping defines how a vendor product becomes an ingredient quantity.

Example

See Product Mapping for the full setup guide.

Conversion factor

The conversion factor tells Mathership how much ingredient stock one ordered product unit creates. Received inventory quantity = Ordered quantity × Conversion factor

Packaging levels

Packaging levels describe nested product packaging. They are useful when a product has multiple layers.

Example structure

In this example, one box contains 6 packs and each pack contains 1 kg. The total quantity per box is 6 kg.

How packaging level conversion works

When you enter a quantity in a packaging unit, Mathership:
  1. Finds the selected packaging level in the hierarchy
  2. Walks down through each level multiplying by quantity_per_parent
  3. Reaches the bottom level which has a unit, such as kg or L
  4. Applies any standard unit conversion if the bottom level unit differs from the ingredient’s base unit
  5. Returns the final quantity in base units
This calculation happens automatically every time you enter a quantity in a stock count, transfer, or waste entry.

Packaging example

A vendor sells flour as a box with 4 bags. Each bag contains 2.5 kg.

Entering quantities in packaging units

When packaging levels are configured on an ingredient, the stock count, transfer, and waste sheets let you enter quantities in those packaging units instead of the base unit. The unit dropdown shows:
  • Base unit, such as kg
  • Each packaging level by name, such as Box or Bag
When you select a packaging unit, the converted base quantity is shown in real time below the input field — for example = 20 kg — so you can confirm the conversion before saving.
The system always stores the quantity in base units. The packaging unit selection is only for convenient entry.

Default unit selection

When you open a stock count, transfer, or waste entry, Mathership automatically selects the most appropriate unit to display.

Packaging breakdown display

Throughout the app, on-hand quantities are shown as a packaging breakdown rather than just a raw base unit number. Format: primary level / base quantity / secondary level Example for flour with packaging levels Box and Bag: This format appears in:
  • Ingredient picker dropdowns
  • Stock count sheet
  • Transfer sheet
  • Waste sheet
  • Ingredient detail panel within storage units
  • Ledger page
  • Suggestion detail sheet

AI-assisted packaging detection

The product mapping sheet has a Get AI factor button shown with a sparkles icon. It reads the vendor product details and the selected ingredient and suggests:
  • A conversion factor
  • Packaging levels with names and quantities per parent

Examples

Always verify AI suggestions against the actual product packaging before saving the mapping.

Automatic factor calculation

If you configure packaging levels manually in the product mapping sheet, Mathership automatically calculates the total factor by multiplying through the hierarchy. Example: Mathership calculates: 12 × 1 = 12 L per carton If the mapped ingredient uses liters as the base unit, the factor becomes 12.

From unit and to unit

A mapping uses a source unit and a target unit.

Common conversions

Receiving orders

Unit conversions are used when receiving vendor orders into inventory. If a product has no mapping, Mathership cannot correctly convert it into ingredient stock.

Partial receiving

When receiving an order, the received quantity can differ from the ordered quantity. Mathership uses the received quantity for the inventory receipt.

Recipes and unit conversions

Recipes use ingredient quantities in the ingredient’s base unit. The ingredient base unit should match how the ingredient is normally consumed. When a POS sale or recipe issue is posted, Mathership reduces stock using the ingredient unit.

POS usage

POS mappings can reduce inventory through recipes or direct ingredient mappings.

Inventory ledger impact

Unit conversions directly affect inventory ledger entries. The ledger stores the converted ingredient quantity, not the vendor order quantity.

Cost conversion

Costs are also affected by the conversion factor. If one ordered product costs €20 and creates 10 kg of stock, the unit cost is €2 per kg. This unit cost is used for inventory value and weighted average cost.

Common workflows

Create a product mapping with packaging levels

  1. Open an order or go to ManageIngredients and open an ingredient
  2. Open the product mapping sheet
  3. Select the vendor product and the ingredient
  4. Add packaging levels — name, quantity per parent, and unit for the bottom level
  5. Click Get AI factor to let Mathership suggest the factor from the product details, or enter it manually
  6. Review the suggested packaging levels and factor
  7. Save the mapping

Use AI-assisted factor calculation

  1. Select the vendor product in the mapping sheet
  2. Select the target ingredient
  3. Click Get AI factor
  4. Review the suggested packaging levels and factor
  5. Adjust any values that do not match the actual product
  6. Save the mapping

Receive an order with conversions

  1. Open the received order
  2. Check which order items are mapped
  3. Select the storage unit
  4. Review the received quantity
  5. Review the converted base quantity shown in the To transfer column
  6. Post the receipt to inventory

Fix a wrong conversion

  1. Open the product mapping
  2. Check the packaging levels and their quantities per parent
  3. Check the bottom-level unit
  4. Correct the factor or packaging levels
  5. Save the mapping
  6. Review affected receipts and ledger entries

Best practices

Use practical base units

Choose base units that match how you manage stock, such as kg for meat and vegetables, L for liquids, and pcs for eggs.

Keep packaging accurate

Packaging levels should match the real product structure, including order, quantity per parent, and bottom-level unit.

Check factors before receiving

A wrong factor can create large stock errors, especially for cases, crates, boxes, and packs.

Use one unit per ingredient

Do not track the same ingredient sometimes in grams and sometimes in kilograms. Use one base unit and convert everything into it.

Verify AI suggestions

The AI factor is a starting point. Verify the suggested factor against the actual product packaging before saving.

Review ledger results

After changing conversion settings, review receipts and ledger entries to confirm quantities and costs look correct.

Common wrong factors

Common problems

Check the product mapping factor, packaging levels, from unit and to unit, whether the ordered quantity was entered correctly, and whether the product was received twice.
Check the product mapping factor, missing packaging levels, wrong bottom-level unit, and whether the product was mapped to the wrong ingredient.
Check that the product is mapped to an ingredient, the ingredient exists and is active, the ingredient has a base unit, the mapping has a valid factor, and a storage unit was selected.
Check the product price, conversion factor, received quantity, and the weighted average cost history from previous receipts.
If the AI factor creates the wrong result, check the packaging levels manually — name, quantity per parent, and bottom-level unit.Edit the packaging levels and factor directly in the mapping sheet.
If the on-hand breakdown shows an unexpected format, check that packaging levels are configured on the ingredient and that the order field on each level correctly places them in the hierarchy from top to bottom.

Ingredients

Manage ingredients and their base units.

Product Mapping

Map vendor products to inventory ingredients.

Receiving Orders

Receive vendor orders and convert products into ingredient stock.

Inventory Ledger

View converted inventory movements and running stock balances.

Recipes

Use ingredient quantities for recipes and POS stock reduction.

Inventory Reports

Analyze stock, movement quantities, costs, and inventory values.
Last modified on June 7, 2026