For the complete documentation index, see llms.txt. This page is also available as Markdown.

How cashback is calculated

This article's section starts at 0:00 in the video.

This is the full reference for the cashback engine: exactly how DollarBack turns an order into a credit amount. If a customer's credit ever looks "wrong", the answer is on this page, usually in discounts, program competition, or a cap.

The pipeline at a glance

For every qualifying order, DollarBack:

  1. Checks eligibility gates: if any fails, no math runs.

  2. Computes a base amount per order line: line price minus discounts.

  3. Deducts portions paid with store credit or gift cards, per your settings.

  4. Lets your programs compete for each line: one winner per line.

  5. Applies the winning program's value, then caps, rounding, and currency.

Everything below is per line item; cashback is never computed on the order as one lump.

Step 1: Eligibility gates

Before any calculation:

  • The order must have a customer: guest orders (no customer on the order) earn no cashback at all.

  • Excluded customer tags: tagged customers earn nothing (Exclude customers from earning).

  • Sales channels: a program restricted to specific channels (web, POS, draft orders) skips orders from other channels.

  • Program date windows: a program outside its start/end dates doesn't participate.

  • Loyalty tiers: when tiers are active, only the programs linked to the customer's tier take part. A customer with no tier, or whose tier is turned off or has no linked programs, earns no purchase cashback. While tiers are active, the customer tag fields of store-credit programs are ignored (discount-code programs still check theirs); the global excluded tags above still apply. See Link cashback programs to tiers.

  • Program customer tags (tiers off): a program with include or exclude tags skips customers who don't match.

  • Discount codes: if the order uses a discount code, every program with Give cashback when discount codes are used turned off drops out.

Advanced section of a purchase program: Who can see this offer, the checkbox Give cashback when discount codes are used, and Restrict to sales channels with Online Store, Shop, Point of Sale and Draft orders.
Each purchase program has its own discount-code checkbox (2) and sales channels (3) in its Advanced section.

Purchase programs have no "N times per period" limit: a customer earns on every qualifying order.

Step 2: The base amount, per line

The base for each line is the line price minus that line's discount allocations:

  • A discount targeted at a product reduces that line's base directly.

  • An order-level discount (e.g. a 10%-off code) is spread proportionally across all lines, so every line's base shrinks by the same ratio. Every discount reduces cashback; there is no way to earn on the discounted-away amount.

Order total vs order subtotal. Your global Base cashback on setting decides what counts:

Mode
Taxes
Shipping

Order Total

Included

Included only if Include shipping costs is on

Order Subtotal

Excluded

Usually excluded. With Include shipping costs on, shipping is added for orders with a single line item and for all-products order goals

In total mode, each line is scaled by the tax-inclusive ratio so that the per-line amounts still sum to the checkout total.

The Cashback Calculation card in DollarBack Settings: Base cashback on (Order Total or Order Subtotal), Maximum cashback per order, Include shipping costs in cashback calculation and Round up cashback to the nearest whole number.
Base cashback on, the cap and rounding are set once for all programs in Settings β†’ Cashback Calculation.

Step 3: Store credit and gift cards are deducted first

No cashback on cashback. Store credit spent on the order is deducted proportionally from every line before calculation, governed by the When a customer pays with store credit setting:

Option
Effect

No cashback

Any store-credit use disqualifies the order entirely

Cashback on full order amount

Credit-paid portion still earns

Cashback on amount paid with real money only

Only the non-credit portion earns (the default mental model: no cashback on cashback)

Gift cards have two separate knobs:

  1. When a customer pays with gift cards: no cashback / full order amount / non-gift-card portion only.

  2. Give cashback when customers purchase gift card products: when off, gift-card product lines are removed from the calculation entirely.

Defaults and exact labels: Settings.

Step 4: Which program claims each line

Competition is winner-takes-all per line. Programs never stack, and the resolution happens in two rounds:

  1. Targeted programs claim their lines first. Any program aimed at specific variants, products, or collections runs before your all-products program. A line claimed by a targeted program is removed from the all-products program's reach, regardless of rate. A 10% collection program beats a 15% all-products program on every item in that collection; the all-products program only sees the lines nothing targeted.

  2. Among targeted programs, the highest cashback for the line wins. There is no ranking of variant over product over collection. If a variant program pays 5% and a collection program containing that variant pays 15%, the collection program wins that line, because it pays more. Fixed-amount programs are compared on their actual payout (amount Γ— quantity), so a $5-per-item program beats 10% on a $40 item and loses on a $60 item.

Order-goal programs sit outside round 1: they compete on amount against every other program for the lines they cover. A goal that loses some of its lines to another program pays only the share of its reward that belongs to the lines it kept, so it can pay part of its reward, or nothing if it loses every line.

On an exact tie for a line, the stage decides: a targeted program beats the all-products program, and both beat an order goal. Between two programs of the same stage, the one listed first on the Manage configurations page (Home β†’ Cashback tab) wins. Different lines in one order can be claimed by different programs, so an order can earn from several programs at once.

Overlap
Winner
Why

Collection at 10% vs all products at 15%

Collection, 10%

Targeted programs claim their lines before the all-products program runs

Product at 8% vs all products at 5%

Product, 8%

Same rule; here it also happens to pay more

Variant at 5% vs collection (containing it) at 15%

Collection, 15%

Both are targeted; the higher cashback wins

Product at 12% vs collection (containing it) at 10%

Product, 12%

Both are targeted; the higher cashback wins

Fixed $5 per item vs product at 10%, item costs $40

Fixed, $5

$5 beats $4; fixed and percentage are compared on payout

Want the store-wide rate to win when it's higher? The engine can't do that for you: a targeted program always claims its lines. Either raise the targeted program's rate, or remove the overlapping products from it. The product-page message estimates using the highest matching rate, so in a collection-10%-vs-store-15% setup it may advertise 15% while the order is credited at 10%; keep the targeted rate at or above the store-wide rate to avoid the mismatch.

Order goals pick the highest threshold met: a $75/$150 ladder pays at most the $150 reward on a $160 order, never both (less if another program wins some of the lines, see above). When a goal program targets specific products, variants, or collections, only spend on the matching lines (after discounts) counts toward the threshold, and the reward is calculated on that same spend; see Set up purchase cashback.

Tier multipliers are snapshotted per order. If the customer is in a loyalty tier with a multiplier, the multiplier in force at calculation time is applied and recorded on the order. Changing tier settings later never retroactively changes past orders' cashback. See Link cashback programs to tiers.

Step 5: Value, caps, and rounding

  • Percentage programs apply their rate to the line's base.

  • Fixed-value programs multiply the amount by the line's quantity (2 units = 2 Γ— the fixed credit). The reward has to fit inside what the customer actually paid for that line after discounts and store credit. If it doesn't, the program pays nothing on that line; the reward is not reduced to fit. This is why a 100%-off order earns nothing; see A discounted order earned less (or no) cashback.

  • Maximum cashback per order: if the order's total cashback exceeds the global cap, all programs and lines are scaled down proportionally, preserving their relative shares. Nothing is dropped; everything shrinks together.

  • Rounding: amounts are truncated to 4 decimal places internally, and the last line absorbs the remainder so the total stays exact to the cent. If Round up cashback is on, each credit is rounded up to the next whole number as the very last step, after the cap. An order can give more than one credit (for example an order goal plus a percentage program, or programs with different expiry), and each one is rounded up on its own, so the rounded total can be slightly above the cap.

Multi-currency

  • Amounts are tracked in both your shop currency and the order's presentment currency. Fixed-value cashback converts using the order's own conversion rate (presentment Γ· shop), not today's market rate.

  • The credit lands in the customer's resolved currency, so a customer shopping your EUR market is credited in EUR.

Worked example (3-line cart with a discount code)

Settings: base = Order Subtotal, no cap, round-up off. Programs: 5% on all products and 10% on the "Serums" collection.

The customer's cart, with a 10%-off order code applied ($12.40 spread proportionally across $124 of items):

Line
Price
Discount allocation
Base
Winning program
Cashback

Serum 30 ml Γ— 1 (Serums)

$58.00

βˆ’$5.80

$52.20

10% (specific claims the line)

$5.22

Gel cleanser Γ— 2

$48.00

βˆ’$4.80

$43.20

5% (all products)

$2.16

Lip butter trio Γ— 1

$18.00

βˆ’$1.80

$16.20

5% (all products)

$0.81

Total

$124.00

βˆ’$12.40

$111.60

$8.19

Points to notice:

  • The serum earned 10%, not 10% + 5%; the collection program claimed the line and excluded it from the all-products program. It would still have won at 10% if the all-products program paid 15%.

  • Every line's base was reduced by its share of the order-level code before any percentage applied.

  • With Round up cashback on, the customer would receive $9.00 instead of $8.19 (both programs are percentage programs with the same expiry, so they are issued as one credit).

  • If a $5.00 Maximum cashback per order were set, each line would scale by 5 Γ· 8.19 (β‰ˆ $3.19 / $1.32 / $0.49).

When the credit actually arrives

Calculation and issuance are separate: the trigger event (created / paid / fulfilled) and the holding period decide when the customer can spend the result; see When credit is issued. Refunds and order edits recalculate as a diff against what was issued, but after the credit is issued only when your plan includes Auto-adjust on refunds and edits and Enable order edit tracking is on; see Refunds, cancellations & order edits.

Common issues

  • "The customer earned less than my percentage": a discount code, store-credit payment, or gift card reduced the base; recheck Steps 2–3.

  • "A fixed reward paid nothing on a discounted or free order": the reward was more than the customer paid for the item (Step 5); see A discounted order earned less (or no) cashback.

  • "Two programs should both apply": they never stack; one wins per line (Step 4).

  • "The store-wide program pays more, but the collection rate was applied": expected. Targeted programs claim their lines before the all-products program runs (Step 4).

  • "No credit at all": walk the gates in Step 1 (a guest order or a discount code are common causes), then A customer didn't receive cashback.

Last updated