Shopify does not natively support applying discount codes to a product’s compare at price. By default, all discounts apply to the current price – the actual price field on the variant – regardless of what the compare at price is set to.
The workaround is to use an app that dynamically calculates the difference between the compare at price and the current price, then adjusts the discount amount so the customer lands at the correct final price. Regios Discounts does this with a single setting: set “How to handle items already on sale” to “Calculate discount based on compare at price.”
Here’s why this happens, and exactly how the fix works.
Shopify’s pricing and discounting systems are separate
In Shopify, pricing and discounting are two independent systems that don’t share all information with each other.
The compare at price is part of the pricing system. It’s a display field that lives on the product variant. It tells your storefront what number to cross out. Nothing more.
Discount codes are part of the discounting system. When a code is applied, Shopify calculates the discount off the current price – the actual price field on the variant. The compare at price is completely invisible to it.
This is by design. Shopify built these systems independently, and the discounting engine has no awareness of what a product “used to” cost.
The result: if your product already has a sale price set, a discount code gets applied on top of it. You end up with a double discount.
What the math actually looks like
Here’s a concrete example:
- Compare at price: $100
- Current price: $80 (already $20 off)
- Discount code: 40% off
What the customer expects: $100 x 0.60 = $60
What Shopify calculates: $80 x 0.60 = $48
That’s a 52% total discount. You intended to give 40%.
For stores that use compare at prices as a long-term strategy (common in fashion, health and wellness, and specialty retail), this affects every discount campaign you run. Influencer codes, welcome series emails, seasonal promotions – every one of them is being calculated on top of an already-discounted price.
The workaround
Since Shopify’s discounting system only knows about the current price, the fix is to account for the existing sale discount inside your discount logic.
The math works like this:
- Target final price: $100 x 0.60 = $60
- Current price: $80
- Discount to apply: $80 - $60 = $20
Instead of applying 40% to $80, you apply a calculated fixed deduction that gets the customer to $60. The key is doing this dynamically – across your entire catalog, for any product, at any discount percentage, in real time.
Shopify has no native way to do this. You need an app.
How to set this up with Regios Discounts
Regios Discounts was the first Shopify app to build this feature.
When creating a discount, find the “How to handle items already on sale” setting and switch it to “Calculate discount based on compare at price.”
One toggle. That’s it.
From that point on, every discount you create will automatically calculate the difference between a product’s compare at price and current price, and adjust the discount amount accordingly. Customers land at the price you actually intended.
It works for:
- Discount codes
- Automatic discounts
- Volume discounts
- Any combination of the above
And because Regios is built on Shopify Functions, it runs directly on Shopify’s servers and works across every sales channel out of the box – no draft orders, no compare at price workarounds, no compatibility issues with your theme.
One thing to be aware of
The compare at price will not appear as a crossed-out value at checkout. Shopify controls the checkout UI and doesn’t allow apps to modify pricing display there.
What this setting fixes is the actual amount the customer pays. The final price will reflect your intended discount off the compare at price, even though Shopify’s checkout shows it as a percentage off the current price.
For most stores, this is a non-issue. The customer gets the deal you promised. You protect your margins.
The short version
Shopify’s pricing and discounting systems are completely separate. Discount codes have no awareness of compare at price, so they apply on top of whatever sale price you’ve set.
The fix is to calculate your discount relative to the compare at price and apply the difference dynamically. Regios Discounts does this automatically with a single setting.
If you’re running discount codes against a catalog with compare at prices, it’s worth checking today.