Wrong cart and product totals in Order Discounts

Topic summary

Main issue: Order discount Functions show cart and line item total/subtotal as identical, conflicting with docs implying product discounts run before order discounts. Screenshots illustrate equal totals/subtotals.

Clarifications/answers:

  • Execution model: Product and order discount Functions run at the same time. Their outputs are later evaluated by the discounts engine, which prefers product discounts first when deciding the best combination.
  • Not a bug: During Function execution, no other discounts are known yet, so totals/subtotals won’t reflect other discounts. This explains why values appear the same in Order discount Functions.

Documentation: Will be updated to clearly state the concurrent execution and the later combination step.

Future control: Discount allocators (in developer preview) will allow more control over how order and product discounts combine.

Outcomes/status:

  • Questions answered: (1) They run concurrently; (2) Values are not incorrect—by design.
  • Actions: Documentation update planned; no fix timeline needed since behavior is intentional.
  • Open items: No ETA provided for doc update or for discount allocators leaving preview.
Summarized with AI on January 4. AI used: gpt-5.

It appears that the total, and subtotal are always the same, at the cart level and the cart line level.

https://help.shopify.com/en/manual/discounts/combining-discounts/examples

The documentation here suggests that product discounts are run first followed by order discounts.

1.) In reality, are order and product discount functions run in parallel?
2.) Is the total/subtotal in the Order discount incorrect - i.e a bug?

If (1), could I request that the documentation is updated as it’s extremely difficult to explain this difference to merchants.

If (2), could I request a timeframe for when this might be fixed, such that we can pass this information on to merchants in the meantime.

2 Likes

Hi Optizio –

Product and order discount Functions are ran all at once, and their outputs are used later in the discounts engine, where, when determining the best discount combination, product discounts are considered first, then order discounts.

It is unfortunately not a bug, as discount Functions can’t know about other discounts when they’re being executed, as it’s long before the discounts engine begins to consider discount combinations and the best one. We’re going to update the documentation to make this clearer.

Discount allocators (currently in dev preview) would allow you to provide more control over the combination of order and product discounts.

-Nick