Skip to content
All blog
Shopify Margin Malaysia Reporting

Per-product profitability on your own store

Chong 7 min read

Every store can rank products by sales. Almost none can rank them by profit, and the ranking changes more than merchants expect when they finally can.

The obstacle is structural: revenue arrives per line item, and most of the costs arrive per order. Getting from one to the other requires attribution decisions, and the decisions have to be defensible rather than convenient.

The five costs that need attributing

Cost of goods, which is already per product if the cost field is maintained — see cost of goods sold for Shopify stores.

Discounts, which may be per line or per order. Order-level discounts need allocating, and Shopify records the allocation it used, which is the figure to read rather than recompute — see Shopify discounts, taxes and line-level allocation.

Payment processing, which is per order and proportional to order value. Allocating it by line value is reasonable and defensible.

Delivery, which is per shipment and driven by weight and destination rather than by value. This is the hard one.

Returns, which are per product but arrive later than the sale, sometimes much later.

Two of the five are naturally per product. Three need a rule, and the rules are where reporting either becomes useful or becomes fiction.

The delivery attribution problem

Worth dwelling on, because it is the attribution most likely to be done badly and it changes conclusions.

A courier charges by weight and destination for the whole parcel. A parcel contains several products. So delivery cost has to be split, and the obvious methods are all wrong in different ways.

By order value penalises expensive items that weigh nothing. A small high-value product carries a large share of a delivery cost it did not cause.

Evenly across lines penalises small add-on items. A cheap accessory absorbs the same delivery cost as the main product, and appears unprofitable.

By weight is the most defensible, because weight is what the courier actually charged for. It requires product weights to be maintained, which most stores have partially.

The practical answer for most stores: allocate by weight where weights exist, fall back to value where they do not, and — more importantly — report delivery cost as its own line rather than burying it inside product margin. A product's margin before delivery and the delivery cost it typically attracts are two useful figures. One blended number that hides an arbitrary allocation is not — see shipping revenue versus shipping cost.

What not to allocate

Restraint matters here, and over-allocation is as damaging as under-allocation.

Advertising, rent, salaries, software and general overhead should not be pushed down to product level. Any method for doing so is arbitrary, the result feels precise, and decisions get made on the arbitrariness rather than on the data.

The exception is advertising traceable to a specific product or campaign, which is genuinely attributable and worth attributing — see paid ads and the margin they consume.

Stop at contribution margin. Revenue less cost of goods, less allocated discount, less processing, less delivery. That figure is defensible, comparable between products, and sufficient for every decision you would use it for. Pushing further adds precision without accuracy.

What the ranking usually reveals

Four patterns that show up repeatedly once the calculation exists.

The best-seller is not the best earner. Frequently it is a high-volume, thin-margin line that anchors the range, and its role is legitimate — but treating it as the star product distorts buying and promotion.

Some products lose money on every sale. Usually heavy, low-value items where delivery exceeds margin, or lines that have been discounted so consistently that the discount is effectively the price.

Small items in multi-item orders are more valuable than they look. They add margin without adding much delivery cost, which is invisible in any allocation that spreads delivery by value or evenly.

Free shipping thresholds change the answer. A product that is profitable at full price becomes marginal when its order qualifies for free delivery, and whether the threshold is set correctly is answerable from this data.

None of those are visible in a sales ranking. All of them affect decisions being made weekly.

Making it a report rather than an exercise

The difference between a one-off analysis and something that changes behaviour.

Automate the attribution rules. Decided once, applied consistently, documented so the numbers can be explained when questioned.

Include returns, lagged. A product with a high return rate has lower true margin than the sale suggests, and the return arrives weeks later — see returns on your own store and what they cost.

Report it monthly, ranked by contribution rather than revenue. Ranking by revenue is what everyone already has and it is the habit worth breaking.

Show the components, not just the total. A product that is thin because of delivery needs a different response from one that is thin because of supplier cost. A single margin percentage does not distinguish them, and the distinction is the actionable part — see inventory and profit: the connection.

Common questions

Why is revenue by product not enough?

Because it says nothing about what each product earned. Cost of goods, allocated discounts, payment processing, delivery and returns all have to be attributed before a ranking means anything, and two of those five arrive at the order level rather than the product level. The profit ranking routinely differs from the sales ranking.

How should delivery cost be allocated across products in an order?

By weight where product weights are maintained, since weight is what the courier actually charged for, falling back to order value where they are not. More important than the method is reporting delivery as its own line rather than burying it in product margin, because allocating by value penalises light expensive items and allocating evenly penalises cheap add-ons.

Should overheads be allocated to individual products?

No. Advertising, rent, salaries and general overhead cannot be pushed down to product level by any non-arbitrary method, and the resulting figures feel precise while being made up. Stopping at contribution margin — revenue less cost of goods, discount, processing and delivery — is defensible and sufficient for the decisions the report informs.

What does per-product profit usually reveal?

That the best-selling product is often not the best earner, that some products lose money on every sale — typically heavy low-value items where delivery exceeds margin — that small items in multi-item orders contribute more than any value-based allocation suggests, and that free shipping thresholds can turn a profitable product marginal.


Related: cost of goods sold for Shopify stores · the real margin on a Shopify order · inventory and profit: the connection


See what you could build

Start a free trial and describe what your business needs in plain language — SmartB Studio builds the module for you.

Start free trial
Get started

No credit card · Cancel anytime · Your data stays yours