Costory Install free

Shopify COGS · Cost per item · Profit margin

Shopify COGS and Cost per item, calculated from your recipes

Shopify’s profit and margin are only as good as the Cost per item behind them. Costory calculates that cost from each product’s recipe (ingredients, packaging, labor and overhead), writes it to Cost per item for every variant, and updates it when an ingredient price changes.

Install free on Shopify

Free for up to 10 products · 14-day trial on paid plans

Updated

Product
Brownie box
Written to Shopify
Cost per item $6.12 from recipe
What one Brownie box costs, line by line
Dark chocolate 200 g $2.80
Butter 150 g $1.35
Sugar 180 g $0.27
Eggs 3 pcs $0.90
Gift box 1 pcs $0.80
Price
$13.99
Gross profit
$7.87
Margin
56%
An example recipe. When the price of an ingredient changes, Costory recalculates the cost and writes the new Cost per item to Shopify.
Short answer

Shopify COGS (cost of goods sold) comes from the Cost per item field of each variant: Shopify records it at the moment of every sale and subtracts it from sales to show gross profit and margin. Costory fills that field for you. It calculates each variant’s cost from its recipe, writes it to Cost per item, and recalculates it whenever an ingredient price changes, while products you resell keep the Cost per item you entered. Cost per item sync is on every plan, including Free for up to 10 products.

How does Shopify use Cost per item for COGS?

Cost per item is the field on each Shopify variant that holds what one unit costs you, and Shopify’s profit reports take product cost from it. Shopify uses it in three places:

  • On the product page. Once a product has a cost, its details page shows a margin based on the full price.
  • At every sale. Shopify records the variant’s cost with the order, and reports profit only for variants that had a cost recorded when they sold (Shopify Help Center).
  • In profit reports. Reports such as Gross profit by product, Gross profit by product variant and Profit margin by order subtract that recorded cost from sales.

So your Shopify profit margin is exactly as accurate as the number in Cost per item. A blank field leaves the sale out of your profit figures, and a cost that is too low makes every sale look better than it was.

Why does a typed-in Cost per item go out of date?

A Cost per item you type in is right on the day you type it and starts drifting the next time a supplier changes a price. For a brand that makes what it sells, it drifts for four reasons:

  • Ingredient prices move. Chocolate going from $14 to $16 per kg adds 0.2 kg × $2.00 = $0.40 to a brownie box, and raises the cost of every other product that uses it.
  • One ingredient sits in many products. Retyping the cost of 40 products after one price change is the step that gets skipped.
  • Labor, packaging and overhead get left out, because they are hard to work out per item by hand.
  • Variants differ. A large size uses more of everything, and each variant needs its own cost.

Because Shopify records the cost at the moment of sale, fixing the field later does not fix those sales: orders placed while the cost was wrong keep that cost in Shopify’s profit reports.

Profit apps have the same gap. They are built to add up ad spend, shipping and fees, but for product cost they read Shopify’s Cost per item, or ask you to type costs in or upload a spreadsheet. Costory fills that gap: it works the cost out from the recipe and keeps Cost per item current, so every report built on it starts from a real number.

How do you calculate COGS per unit from a recipe?

Costory calculates the cost of one unit of each variant from its recipe: each ingredient line is converted to the ingredient’s unit, priced and adjusted for waste, then the batch is divided by its yield and overhead is added.

line cost = quantity in the ingredient’s unit × price per unit ÷ (1 − waste)

labor = minutes × hourly rate ÷ 60

cost per item = (material lines + labor lines) ÷ yield + overhead per item

Units and packs

Each ingredient has a unit (mg, g, kg, ml, l, mm, cm, m, cm², m² or pieces) and can be bought in packs, such as a bunch of 10 stems or a 25 kg sack. The recipe can use grams while the price is per kg.

Waste

10 stems at $1.20 with 10% waste cost 10 × $1.20 ÷ (1 − 0.10) = $13.33, because you buy more than ends up in the product.

Yield

One batch can make many items. A dough that costs $8.40 and makes 24 cookies adds $8.40 ÷ 24 = $0.35 to each cookie. More in recipe costing for food and beverage brands.

Semi-finished goods and components

Doughs, syrups and bases have their own recipe and go into products as one line (Starter and up). A product can also contain another product, such as a bouquet in a vase or a gift set (see bundle and gift box costing).

Labor and overhead

Labor lines use roles with hourly rates. Overhead is a percentage of materials (or materials and labor), a fixed amount per item, or monthly expenses ÷ planned quantity, for all products, a collection, a tag or a product type.

Sizes and options

Option modifiers scale the recipe per variant, such as S ×0.6 and L ×1.5 (Starter and up). Every variant gets its own Cost per item in Shopify.

In the app, “How it is calculated” shows where each number of the cost comes from, so you can check it line by line.

Worked example: the COGS of a brownie box

A brownie box made from five ingredients costs $6.12 to make. At a price of $13.99 it earns $7.87 of gross profit, a 56% margin.

Brownie box: cost per item from the recipe
IngredientIn the recipePriceCalculationLine cost
Dark chocolate 200 g $14.00 / kg 0.200 kg × $14.00 $2.80
Butter 150 g $9.00 / kg 0.150 kg × $9.00 $1.35
Sugar 180 g $1.50 / kg 0.180 kg × $1.50 $0.27
Eggs 3 pcs $0.30 / pcs 3 pcs × $0.30 $0.90
Gift box 1 pcs $0.80 / pcs 1 pcs × $0.80 $0.80
Cost per item (COGS of one box)$6.12

gross profit = price − cost per item = $13.99 − $6.12 = $7.87

margin = gross profit ÷ price = $7.87 ÷ $13.99 = 56%

Add labor and overhead

The same box with 6 minutes of work at $18 an hour, and its share of $600 a month of rent and other overhead spread over 1,200 boxes a month:

Brownie box: cost per item with labor and overhead
PartCalculationCost
Ingredients and packagingthe recipe above$6.12
Labor6 min × $18.00 / h ÷ 60$1.80
Overhead$600 a month ÷ 1,200 boxes$0.50
Cost per item$8.42

On ingredients alone the box shows a 56% margin. With labor and overhead the cost is $8.42 and the margin at $13.99 is 40%: ($13.99 − $8.42) ÷ $13.99. That gap is what a Cost per item typed from the ingredient list misses.

Try the arithmetic with your own numbers in the free product cost calculator, recipe cost calculator or margin calculator.

What happens to Cost per item when an ingredient price changes?

When an ingredient price changes, Costory recalculates the cost of every product that uses it and writes the new Cost per item to Shopify, with no retyping. In the example, chocolate goes from $14 to $16 per kg:

Brownie box before and after the chocolate price change
FigureBeforeAfter
Dark chocolate, per kg$14.00$16.00
Chocolate line (200 g)$2.80$3.20
Cost per item in Shopify$6.12$6.52
Margin at $13.9956%53%
Price by the rule ending(margin(cost, 55%), 0.99)$13.99$14.99
Margin at the rule price56%57%
  1. The price changes. You edit the ingredient’s price, or, on Growth and Pro, receive a purchase at a new price: the ingredient price then follows your purchases by the method you choose, weighted average (the default) or last purchase.
  2. Costory recalculates. Every product that uses the ingredient is recalculated, including semi-finished goods and the products they go into, and each new cost is saved with its reason in the cost history.
  3. Cost per item is updated. The new cost is written to each changed variant in Shopify. Sales from then on are recorded at $6.52; earlier orders keep $6.12.
  4. Your price rule reacts. On Starter and up, the rule proposes $14.99 with the margin before and after, or applies it automatically if you choose. On Free, you apply the rule price on the product page. Every change is logged in History with one-click rollback. More in margin-based pricing for Shopify.

On Pro, purchases in other currencies use daily exchange rates, and a rate change recalculates the cost as well.

What about products you resell without a recipe?

Products you buy and resell as they are keep the Cost per item you entered in Shopify, and Costory uses that value as their cost for margins, reports and price rules. Costory imports it when you install, so resale products show a margin from the first day.

  • Your own value stays yours. Costory keeps the Cost per item you entered apart from the one it writes. When a product no longer has a recipe or another cost in Costory, it writes your value back, or clears the field if it was empty.
  • Purchases set the cost on Growth and Pro. A product bought for resale through Costory’s purchases takes the cost of its last receipt, with its share of delivery and other costs (landed cost), and that cost goes to Cost per item.
  • Mixed catalogs work. Products you make are costed from recipes, products you resell from your Cost per item or purchases, and both feed the same reports and price rules.
  • Resold items can go into bundles. A vase or a card added to a made product brings its own cost into the bundle’s Cost per item.

Costory is not a full profit dashboard: it does not import ad spend or build a profit and loss statement. Its job is the product cost line, and the gross profit by product and by order that follows from it.

Which plan do you need for Shopify COGS?

Cost per item sync is on every plan. Paid plans add more products and more ways the cost is built; each has a 14-day trial and is billed by Shopify in USD.

Costory plans for COGS and Cost per item
PlanPriceWhat it adds for COGS
Free$0Recipes and costs for up to 10 products, Cost per item sync, labor and overhead, profit reports for the last 30 days
Starter$12.99 / monthUp to 150 products with recipes, semi-finished goods, option modifiers for variant costs, price proposals, full profit reports
Growth$39 / monthUnlimited products; purchases set ingredient prices and resale costs, with delivery split across lines; actual order composition corrects the cost of an order
Pro$99 / monthPurchase currencies with daily exchange rates (a rate change recalculates costs), staff roles that control who sees costs
Install free on Shopify

Every store starts on Free. Compare plans

Questions about Shopify COGS and Cost per item

Where do I find COGS in Shopify?

Shopify keeps product cost in the Cost per item field of each product or variant in the admin. For a period, its profit reports (Gross profit by product, Gross profit by product variant, Profit margin by order) subtract the cost recorded with each sale from sales. Sales of variants that had no Cost per item when they sold are left out of those reports.

Does Costory overwrite the Cost per item I already entered?

Only for products that get a cost in Costory: from a recipe, from a purchase received in Costory (Growth and Pro) or from a cost typed in Costory. Products without one keep the Cost per item you entered, and Costory uses it as their cost. Your own value is stored apart, so if a product later loses its Costory cost, Costory writes your value back, or clears the field if it was empty.

Will a new ingredient price change the cost of past orders?

No. Shopify records the cost of each sale when it happens, so orders placed before the change keep the old cost and new orders use the new one. Costory works the same way in its own profit reports: each order line keeps the cost it was sold at.

Should COGS include labor and overhead?

That is your choice: Cost per item holds whatever the recipe includes. Costory can add labor lines (minutes × an hourly rate) and overhead rules (a percentage, a fixed amount per item, or monthly expenses ÷ planned quantity) on every plan, including Free. If you count only materials as COGS, leave labor and overhead out and the cost is ingredients and packaging only.

Do profit apps use the cost Costory writes?

Costory writes to Shopify’s standard Cost per item field, which many profit apps read as their default source of product cost. Check the COGS source setting in your profit app: some stop reading Shopify’s value for a product once you edit its cost by hand there.

Is Cost per item sync included in the free plan?

Yes. Cost per item sync is on every plan, including Free, where up to 10 products can have a recipe. Starter ($12.99 a month) raises the limit to 150 products, and Growth ($39) and Pro ($99) have no limit. You can turn the sync off in Settings with “Write costs to Shopify”.

Keep Cost per item true to your recipes.

Free for up to 10 products. Paid plans start with a 14-day trial.

Install free on Shopify