MillMargin / Guides / Main product cost, any mill

Cost per kg of your main product after by-products, for any mill

Rice, flour, dal or cotton lint: a mill buys one raw material and sells one main product plus by-products. The cost of the main product comes out the same way every time. Here is the method once, worked on a wheat lot, then mill by mill.

By the MillMargin team · Updated 28 Nov 2026 · 7 min read

The short answer

Add up everything the lot cost you. Take off what the by-products will fetch, net of their selling costs. Divide what is left by the kilos of main product. Shrinkage (moisture, dust, stones) goes on the sheet at zero value, so the kilos still add up.

Main product cost per kg = (raw material + processing + packing − net by-product value) ÷ main product kgAccountants call this the by-product method. Multiply by 40 for cost per 40 kg, or by 1,000 for cost per tonne. Figures are in your own currency.

Worked example: one wheat lot into flour

A flour mill grinds 100,000 kg of wheat bought at 80 per kg. It gets 75% flour, 22% bran and loses 3% to moisture and cleaning.

LineKgRate per kgAmount
Wheat in100,00080.008,000,000
Milling, labour, power, bags600,000
Bran (22%), net of selling costs22,00045.00−990,000
Moisture and cleaning loss (3%)3,0000.000
Net cost of flour75,0007,610,000

Illustrative figures. Weights add up to the wheat in: 75,000 + 22,000 + 3,000 = 100,000 kg.

So the flour costs 7,610,000 ÷ 75,000 kg = 101.47 per kg. The wheat alone is 80 per kg, but only three kilos in four come out as flour, which is why the cost per kg of flour is well above the cost of the grain.

The same sheet, mill by mill

Only the names change. The kilos in, the by-products credited and the divisor follow the same pattern.

MillRaw material inMain product (divide by)By-products credited
Rice millPaddy or brown riceHead riceBroken, bran, husk
Flour millWheatFlour (maida, atta)Bran, screenings
Dal millWhole pulsesDalHusk, broken pieces (chuni), powder
Cotton ginSeed cottonLintCottonseed, gin waste
Oil millOil seedOilCake or meal (see the note below)

For a full rice lot, with how hard each by-product rate pushes the cost, see head-rice cost per kg after by-products.

When the by-product method stops working: oil mills

The method assumes the by-products are worth little next to the main product. That holds for bran, husk, broken and cottonseed. It does not always hold for an oil mill: on many seeds the cake or meal earns as much as the oil, or more, and its price can swing the oil cost far more than anything you do in the mill.

When that happens, treat oil and cake as joint products and share the cost by what each sells for:

Share of cost for each product = its sales value ÷ total sales value of all products

Until you do that, credit cake at a net rate you are confident of, and read the oil cost per kg as a guide rather than a floor for your price.

Where the by-product credit goes wrong

  • Yesterday's rate. By-product prices can move faster than the raw material. Cost at the rate you can sell at this week.
  • Gross instead of net. Bagging, loading, freight and brokerage come off by-product sales before you credit them.
  • Dividing by the wrong kilos. Divide by the main product, not by the raw material in.
  • Leaving out shrinkage. Moisture and dust carry no value, but they belong on the sheet so the weights add up.
  • By-product you use yourself. Husk or cotton stalks that fire your own boiler are worth the fuel they replace, not the outside sale rate.

A 30-second check on any sheet

  1. Do the output kilos (main product + by-products + loss) add back to the kilos in?
  2. Is every by-product at this week's rate, net of its selling costs?
  3. Is packing in the total before you divide?
  4. Is the divisor the main product's kilos?
  5. Is any by-product worth as much as the main product? Then split by sales value.

Questions mills ask

Does this work for mills other than rice?

Yes. Any mill that turns one raw material into one main product plus lower-value by-products uses the same sheet: flour mills, dal mills and cotton gins as much as rice mills.

What if a by-product is worth as much as the main product?

Then it is a joint product, not a by-product. Share the cost between them by sales value instead of crediting one against the other. Oil mills are the usual case.

Should by-products be credited at gross or net price?

Net. Take off bagging, loading, delivery and brokerage on the by-product sale before you credit it.

Run these numbers on your own lot, for any mill, in about a minute.

Start free — 30 days of Pro included
Keep the books for these lots in MillMargin Ledger

Purchases and sales by weight or count, party statements on WhatsApp and the bank matched every month — on the same account as Costing.

See MillMargin Ledger