Why does my discount show $0.00 in the order confirmation email preview?

If your order confirmation or discount email preview shows a $0.00 discount total, the culprit is almost always the sample data behind the Preview button, not your actual discount setup.

discountsemailnotificationsliquid

What's going on

"Why does my order confirmation email show $0.00 for the discount even though the customer definitely used a code?" is a recurring question in Shopify's merchant community, and it almost always traces back to one of two things: either the merchant was looking at the Preview pane in Settings > Notifications (which renders a built-in sample order, not a real one), or a real order's discount genuinely didn't apply the way the merchant expected.

The Preview button under Settings > Notifications is convenient for checking layout and branding, but it is not a reliable way to validate dynamic data like discount totals, line-item discount allocations, or applied discount codes. Shopify generates a synthetic sample order behind the scenes for that preview, and it doesn't always carry the same discount fields a genuine completed checkout does — so a template that is working perfectly in production can still show $0.00 in preview.

The fix isn't a code change to the template in most cases; it's changing how you test. Once you validate against a real (or test-mode) order with an eligible discount actually applied at checkout, the discrepancy usually disappears — confirming the template was fine all along.

Why it happens

Shopify's notification template editor includes a Preview pane that lets you check formatting without placing a real order. To do this, it substitutes a built-in sample order in place of live checkout data. That sample order is meant to exercise the general shape of an order (customer name, line items, shipping address, totals) but doesn't necessarily carry a fully realistic discount record the way an order that actually went through checkout with a code or automatic discount does — so any Liquid referencing discount amounts, discount codes, or per-line discount allocations can legitimately render as zero or blank in that preview even though the same template works correctly for real customers.

Separately, on real orders, a $0.00 or missing discount can be a genuine configuration issue: the discount code or automatic discount wasn't actually eligible for that cart (minimum spend not met, wrong product/collection scope, expired or not-yet-active date range, customer eligibility restriction), or it was cancelled out by combination rules when stacked with another discount. Because both causes produce the identical symptom — a discount total that reads zero — it's easy for merchants to assume their template or app is broken when the real issue is either the preview mechanism itself or the discount's eligibility rules.

5 ways to fix it

1

Don't trust the Preview button — test with a real (or test-mode) order instead

The Preview pane in Settings > Notifications renders your template against Shopify's built-in sample order, and that sample data does not always populate discount-related fields the same way a genuine order does. Before assuming your template is broken, place a real test order (or a test-mode order if you're using Shopify Payments' test mode / the Bogus Gateway on a dev store) with a discount code actually applied at checkout, then look at the resulting email or order-status page. If the discount shows correctly there, your Liquid is fine and the preview was simply misleading you.

2

Confirm you're referencing supported, current Liquid objects for discounts

Notification templates are Liquid, and the objects available for discounts (order-level discount codes vs. per-line-item discount allocations) have specific, documented names and only populate when that type of discount actually applies to the order being rendered. If your template pulls from a line-item discount field but the discount you tested with was an order-level discount (or vice versa), it will legitimately show as zero even on a real order. Check Shopify's current notification Liquid reference to confirm you're using the right object for the discount type you're testing, and update any older snippets that may reference deprecated variables.

3

Check whether the discount is actually eligible to apply to that order

A $0 discount total on a real (not preview) order usually means the discount didn't actually apply — a common cause when merchants build a custom email test by hand rather than checking out normally. Confirm the discount code or automatic discount has correct eligibility rules (minimum purchase, specific products/collections, customer/segment restrictions, active date range) and that the cart used in your test order actually qualifies. Combined discounts (a code plus an automatic discount) can also partially or fully cancel out depending on your combination settings, which will legitimately show as a lower or zero net discount.

4

Use Shopify's live chat/support or the Community if the discrepancy persists on real orders

If a genuine, eligible discount is applied at checkout, the order shows the discount correctly in the Shopify admin order detail, but the notification email still renders zero, that points to a template bug worth escalating. Shopify support or the Community forums can confirm whether it's a known rendering issue with your theme/template version versus something in your custom Liquid edits.

5

If you're customizing templates heavily, version and diff your changes

Because notification templates are edited as raw Liquid/HTML with no built-in preview-vs-production parity guarantee, keep a saved copy of the last known-good template before making edits. If a discount field breaks after a template edit, you can quickly diff against the previous version rather than guessing which change caused it.

Bottom line

Nine times out of ten, "the discount preview shows zero" is a false alarm caused by testing against the built-in sample order instead of a real order with a real, eligible discount applied — Shopify's native tools (a genuine or test-mode order, plus the current notification Liquid reference) resolve it without installing anything. If you're frequently building or auditing custom discount logic and want a faster way to validate combinations and eligibility before they go live, that's a case where a dedicated discount-testing or QA app can save time, but it's not required to fix this specific symptom.

Still Stuck?

Browse the rest of the problem library, run a free storefront scan to catch issues like this automatically, or email us and we'll work out a custom solution for it.