Gross Margin vs. Contribution Margin for Shopify: Formula and Example

UNIT ECONOMICS & FINANCE8 min read

Gross margin subtracts the defined cost of goods sold. Contribution margin can go further by including fulfillment, payment fees, and acquisition costs.

Table of Contents
  1. Gross margin: product cost compared with net sales
  2. Contribution margin: continue down the variable-cost stack
  3. One Shopify example, two margin answers
  4. Choose the right measure for the decision
  5. Keep revenue and cost definitions aligned
  6. Common comparison mistakes
  7. FAQs

Gross margin = (net sales − cost of goods sold) ÷ net sales × 100.
Contribution margin = (net sales − selected variable costs) ÷ matching net sales × 100.
The second measure can include costs below gross profit, such as fulfillment, payment fees, and advertising.

Gross margin and contribution margin both show what remains as a share of sales, but they use different cost scopes. Gross margin subtracts the cost of goods sold under your chosen accounting definition. Contribution margin can subtract additional variable costs required to sell and fulfill an order. Shopify merchants often need both views: one to understand product economics, and another to check whether an order can support acquisition and operating costs.

The Shopify Profit Margin Calculator displays gross margin from price and product cost alongside contribution after entered fulfillment, Shopify and Stripe fees, and ad cost. Its gross margin is a simple per-order view based on the values you enter; it does not reconcile discounts, refunds, tax, or the accounting treatment in your Shopify reports.

For more on the revenue base and product-cost definition, see the ecommerce gross margin formula guide. To model discount and shipping subsidy alongside both margins, use the gross margin calculator with shipping.

Gross margin: product cost compared with net sales

Gross profit is the amount left after subtracting the defined cost of goods sold from net sales. Gross margin expresses that gross profit as a percentage of the same net sales. For example, if net product sales are $80 and cost of goods sold is $32, gross profit is $48 and gross margin is $48 ÷ $80 = 60%.

The phrase “cost of goods sold” needs a consistent definition. Product purchase or manufacturing cost is central; businesses may also treat inbound freight, duties, and other inventory costs as part of inventory cost under their accounting policy. Match the figure to your financial reporting method and avoid counting landed costs twice.

Shopify's profit reports documentation describes gross profit and gross margin by product and variant. It notes that profit reporting depends on product cost information and that discounts and refunds affect net sales and the margin shown for a period. A simple product-page price less cost calculation can therefore differ from the report for actual discounted or refunded sales.

Contribution margin: continue down the variable-cost stack

Contribution is the revenue remaining after the variable costs selected for a decision. A Shopify order model may subtract product cost, outbound shipping subsidy, pick and pack, packaging, payment processing, applicable platform charges, and ad acquisition cost. The exact list depends on the question. Contribution margin divides that remainder by the matching net sales basis.

Contribution is not automatically operating profit or company net profit. Fixed costs such as payroll, rent, software, and monthly service retainers may be outside an order-level calculation. A positive contribution helps pay those expenses but does not prove the business is profitable for the month.

Keep contribution dollars visible alongside the percentage. A 40% contribution margin on a $20 sale leaves $8 before fixed expenses; a 25% contribution margin on a $100 sale leaves $25. The percentage helps compare the share retained, while the dollar amount helps assess how much one order can pay toward overhead and growth.

One Shopify example, two margin answers

Assume an order has $80 in net product sales and $32 of product cost. For an illustrative contribution view, also include $7 in fulfillment, 2.9% + $0.30 payment processing, a 0.5% separate platform transaction fee, and $18 of ad cost per order. These fees are examples for arithmetic only; they are not a quote or a claim about the charges on a particular Shopify plan or payment route.

First calculate gross profit and gross margin:

  • Gross profit = $80 − $32 = $48.
  • Gross margin = $48 ÷ $80 × 100 = 60%.

Then continue to contribution after the listed order costs:

  • Payment processing = $80 × 2.9% + $0.30 = $2.62.
  • Platform fee assumption = $80 × 0.5% = $0.40.
  • Contribution = $80 − $32 − $7 − $2.62 − $0.40 − $18 = $19.98.
  • Contribution margin = $19.98 ÷ $80 × 100 = 25.0% when rounded to one decimal place.
MeasureCosts subtractedResult
Gross profitProduct cost$48.00
Gross marginGross profit ÷ net sales60.0%
Contribution after adsProduct, fulfillment, processing, platform fee, ad cost$19.98
Contribution marginContribution ÷ net sales25.0%

The gap is not a contradiction. It shows the additional costs required to acquire and fulfill this order. The result still excludes any costs not listed, including returns, customer support, fixed overhead, and taxes. If the sale price is discounted, replace $80 with net sales after the discount and recalculate any fees charged as a percentage of that amount.

Enter your actual assumptions in the gross and contribution margin calculator to compare both outputs. Use the discount calculator when you need to model how an offer changes the sale price, contribution per order, and order volume required to preserve total contribution.

Choose the right measure for the decision

Use gross margin to compare product economics under a stable COGS policy, review supplier price changes, and identify items whose product costs consume a large share of net sales. It can support assortment and pricing review, but it does not show every cost required to acquire and deliver a Shopify order.

Use contribution margin when evaluating a promotion, paid acquisition, free shipping, or a change in payment and fulfillment methods. Include the variable costs triggered by the decision and keep the sales basis aligned. If advertising is included, label the figure as post-ad contribution margin; if it is excluded, call it pre-ad contribution margin.

Use company net profit margin for a defined accounting period after the applicable operating expenses and other recognized items are included. Do not derive a monthly net margin by taking a single order's contribution rate and assuming every order has the same product mix, return pattern, payment route, and acquisition cost.

Keep revenue and cost definitions aligned

Discounts and refunds lower retained product sales. If the denominator reflects the discounted amount, percentage fees should use the chargeable amount the provider actually bills. Decide whether customer-paid shipping is part of revenue; if it is, include the related shipping expense in the same contribution model. Sales tax collected for remittance should be treated consistently with the store's reporting and accounting policy, not casually counted as retained product revenue.

For a reporting period, compare sales and costs from the same date range and currency. Shopify notes that gross-margin reporting depends on cost-per-item data recorded for products. Update product costs when supplier terms or inventory costs change, and document the source and effective date. For a scenario calculator, use current assumptions and label them as estimates; for actual performance, reconcile against order, refund, payment, and fulfillment records.

Common comparison mistakes

  • Calling gross margin “profit after ads” when advertising is not in the cost scope.
  • Calling contribution margin “net margin” before period overhead is included.
  • Dividing by list price after using discounted net sales in the numerator.
  • Comparing periods that treat refunds, shipping, or taxes differently.
  • Counting inbound freight in landed COGS and again as a separate cost.
  • Applying a fee percentage to the wrong transaction base or adding a fee that does not apply.
  • Comparing only percentages while ignoring contribution dollars per order.
  • Treating product costs in a report as current when costs were changed after the selected sales period.

FAQs

Is gross margin higher than contribution margin?

Often, because a contribution calculation may subtract fulfillment, payment, platform, and advertising costs in addition to product cost. The figures depend on definitions; if contribution omits costs that gross margin includes, the comparison may not follow that pattern.

Does Shopify gross margin include advertising?

Shopify's product gross-margin calculation uses net sales and product cost in its profit reports. Advertising is a separate acquisition cost and should be included in a separately labeled contribution or marketing-profit view when relevant.

Can contribution margin be called net profit?

Not when fixed operating expenses and other period costs remain outside the calculation. Contribution is the amount left to help pay those costs and then contribute to profit.

Which margin should I use to decide whether to run a discount?

Review contribution per order and contribution margin after the discount, using the promoted sales amount and the costs triggered by the offer. Then check whether the volume hurdle, inventory, and campaign costs make sense. Gross margin alone does not account for every promotion cost.