Filed under Auto Markdown

How to Exclude Sale Items From Discount Codes on Shopify

Shopify has no exclude-sale-items setting. Six ways to keep discount codes off marked-down products, with the trade-offs and upkeep of each.

Shopify has no checkbox that keeps a discount code off products that are already marked down. To make Shopify exclude sale items from discount codes, you limit the discount to a collection that contains only full-price products, and you build that collection on a compare-at price condition so it drops anything you put on sale. Shopify’s developer documentation gives the instruction in one sentence: “For a native Amount off products discount, scope the discount to a collection that doesn’t contain the product” (shopify.dev, Discount Function API).

That covers product-level codes and automatic discounts. It does not cover an amount off order code. The same page says a native Amount off orders discount “applies to the whole order and has no setting that excludes products.” For those codes the choices are to rebuild the code as a product discount, to accept an app that rejects the code for the whole cart, or to have the discount logic built on Shopify Functions.

We build Auto Markdown, a Shopify app that puts slow-selling products on sale by rule, so what a welcome code does to a product nobody marked down by hand is a question we have to answer for our own users. This guide sets out every method in one place: what each does for product codes, order codes and automatic discounts, what it costs to maintain, and where Shopify’s documentation says nothing at all.

Key takeaways

  • Shopify’s documentation does not describe a native “exclude sale items” setting. The documented control is inclusion: an amount off products discount limited to specific collections.
  • A collection built on Compare at price is not set holds your full-price products and follows them on and off sale. A product with even one variant missing a compare-at price still matches, so single-variant sales leak through.
  • An amount off orders discount cannot skip line items. shopify.dev states that it “has no setting that excludes products.”
  • Combination settings govern discount-with-discount. A compare-at sale is a price, not a discount, so no combination checkbox reaches it.
  • Apps that block codes by rejecting them remove the code from the whole cart, not from the sale line. shopify.dev documents that limit and one blocker’s own listing repeats it.

Why a discount code lands on sale items in the first place

A compare-at sale and a discount are separate machinery that produce a similar-looking result. Shopify’s sale pricing page says so directly: “Using sale prices is different from setting up discounts,” and when a sale price and a compare-at price are both set, “only the sale price is displayed at checkout” (Shopify Help Center, Setting sale prices for products).

So when checkout works out a discount, it starts from the Price field, and during a sale that field already holds the reduced price. The compare-at field is a display value: Shopify’s developer reference describes the compare-at amount on a cart line as “used to calculate and display savings for customers.” We covered how the field behaves everywhere else in our guide to the Shopify compare-at price; for this post, the point is that nothing in the discount engine reads it.

The other half of the problem is how eligibility is expressed. Shopify’s amount off discounts page gives two options for a product discount: “select Specific products, and then add your products,” or “select Specific collections, and then add your collections” (Shopify Help Center, Amount off discounts). Both are lists of what is included. The page describes no “everything except” option and nothing keyed to sale status.

What Shopify’s documentation says, page by page

Blogs disagree about whether a native exclusion exists, so here is what each of Shopify’s own pages says, as read on 3 December 2026.

Shopify pageWhat it says about excluding sale items
Discount codes FAQNone of its 21 questions covers excluding products or sale items. It states that discounts “are different from sale pricing with compare-at prices.”
Amount off discountsApplies to offers specific collections or specific products. No mention of compare-at price, sale price or exclusions.
Combining discountsNo mention of compare-at price, sale price or sale items.
Automatic discountsNo mention of compare-at price, sale price or exclusions.
Discount codesNo mention. It caps hand-picked entitlements: “A discount code can apply to up to 100 specific customers, products, and variants.”
Setting sale prices for productsNothing on whether discounts apply to sale items.
shopify.dev, Discount Function APIStates the position outright: scope a product discount to a collection that does not contain the product; an order discount “has no setting that excludes products.”

Put plainly: Shopify’s documentation does not describe a native setting that excludes sale items, meaning products with a compare-at price, from a discount code or an automatic discount. Every method below either uses inclusion to get the same result or adds logic Shopify does not ship.

Method 1: Make a Shopify discount code exclude sale items with a full-price collection

Use this method first. It is free, it uses only documented features, and once set up it needs no attention when products go on sale. It is also the general answer to how to exclude products from a discount in Shopify: you leave them out of the collection the discount points at.

The compare-at conditions, exactly as Shopify lists them

Shopify’s collection conditions page lists a Compare at price condition with six matching options: is, is not, is greater than, is less than, is set and is not set (Shopify Help Center, Collection conditions). The Shopify mobile app labels the last two “is not empty” and “is empty.”

The two that matter here are defined precisely, and they are not mirror images:

  • is not set: “A product matches when any of its variants has an empty Compare-at price value.”
  • is set: “A product matches when all of its variants have a Compare-at price value. The value can be 0.”

A note on vocabulary: older tutorials call this an automated or smart collection. Shopify’s current pages describe collections as having sources, and a collection whose Products source uses conditions is what those tutorials mean.

Build the collection

These steps follow Shopify’s page on creating collections (Shopify Help Center, Creating collections).

  1. From your Shopify admin, go to Products > Collections and click Add collection.
  2. Give it a name you will recognise in the discount form, such as “Full price — code eligible”.
  3. In the default Products source, click Add condition.
  4. Select Compare at price as the attribute and is not set as the matching option.
  5. To keep a brand or product type out regardless of price, add it in the source’s Exclude section, which the conditions page limits to Type, Vendor, Category and Tag conditions.
  6. Decide whether shoppers should see the collection. Shopify’s page says a collection used as input for something else, such as a group of products assigned to a discount, can be left “unpublished from all sales channels.”
  7. Click Save, then check the product list against what you expect.

Attach the discount to it

  1. Go to Discounts and create a discount of the type Amount off products, as a code or as an automatic discount.
  2. Set the percentage or fixed value.
  3. In the Applies to section, select Specific collections and add the full-price collection. Add nothing else.
  4. Set eligibility, minimum requirements, usage limits and combinations as usual.

One detail on the same help page changes how a scoped code behaves: “Only items that your discount applies to can count towards the minimum purchase amount.” A “15% off over $100” code scoped to full-price products needs $100 of full-price products in the cart. For a code that already exists, Shopify’s managing discounts page says you can edit a discount’s settings, so an existing amount off products code can be pointed at the new collection. An existing amount off orders code is a different case, covered in Method 3.

What happens when a product goes on sale after the code was created

Nothing needs editing. The discount refers to the collection, and the condition decides the collection’s membership. Add a compare-at price to every variant of a product and it stops matching “is not set,” drops out, and the code stops applying to it. Empty the field when the sale ends and the product comes back.

If the cart then holds nothing the code applies to, Shopify’s discounts FAQ gives the message the customer sees: the “discount code isn’t valid for the items in your cart.” In a mixed cart the code applies to the full-price lines only.

Shopify’s conditions page gives no timeframe for how quickly a collection picks up a product change. It does include a fix for a collection that has not updated: make a temporary change to any condition, save so that “the collection refreshes,” then revert and save again. Our judgment: when a large sale starts, open the full-price collection and confirm the sale products have left before the code goes out in an email.

The gaps in the condition

The method fails in predictable ways, all of which follow from how the condition is defined.

  • Sales on some variants only. “Is not set” matches when any variant has an empty compare-at price. Mark down one size and the product stays in the collection. Shopify’s page says “A Products source includes a product with all of its variants,” so the code applies to the marked-down variant too.
  • Compare-at price equal to or lower than Price. The conditions page describes no condition that compares one field with the other. A product whose variants all carry a stale compare-at value that is not higher than Price shows no strikethrough, since Shopify’s sale pricing page requires the compare-at price to be higher for a sale to display. It has still left your full-price collection, so the code refuses a product that is not on sale: safe for margin, bad for support tickets.
  • Zero is a value. The conditions page says “a compare-at price of $0.00 USD isn’t considered empty.” A product with 0 in every variant’s compare-at field counts as set.
  • Compare-at used as a permanent list price. If the field holds a manufacturer’s price on everything, year-round, the full-price collection will be nearly empty. Use tags instead.
  • More than one collection on the discount. Add “Full price” and also “New arrivals,” and a marked-down new arrival is still eligible through the second collection.

The fix for the second and third gaps is data hygiene: clear compare-at fields that are not doing a job, and clear them to empty. The first gap needs a different construction.

Closing the variant gap: exclude a sale collection instead

Shopify’s collection pages document two features that combine into a stricter version. This is our reading of the documented operators, not a recipe Shopify publishes, so check it on one product with mixed variants first.

First, a sale collection that catches partial sales. The conditions page says that in a Products source, “the condition is true if any variant matches the condition.” A collection on Compare at price is greater than 0 should therefore contain every product where at least one variant holds a compare-at value above zero, unlike “is set,” which needs every variant to carry one.

Second, an exclusion. The creating collections page says you can exclude products “by excluding another existing collection,” and that “product exclusions always override any manual or automatic product inclusions.” In the full-price collection’s Products source, click Exclude collections, then Add collection in the Exclude section, pick the sale collection, and save.

The result is conservative: a product with one marked-down size is excluded entirely. Shopify also rations the feature: “Your store can have a maximum of 5 collections that exclude another collection.” One of the five is well spent here.

For true variant-level precision, Shopify’s page says to “use a Variants source when you want a collection to only include specific variants,” and the discounts FAQ confirms that “individual product variants can be added to a collection that you apply a discount to.” The conditions page does not spell out how “is not set” is evaluated inside a Variants source, so test before trusting it.

Method 2: A tag-based collection

The second free method swaps the compare-at condition for a tag. You tag products that codes must not touch, and the full-price collection is defined by the absence of that tag. Shopify’s conditions page gives the Tag condition the options “is” and “is not” when including products, and only “is” inside the Exclude section, so either of these works:

  • A Products source with the condition Tag is not no-codes.
  • A Products source defining your normal catalog, with Tag is no-codes in its Exclude section.

Attach the discount as in Method 1. Shopify’s tags page covers the mechanics: tags “are not case sensitive,” and you add or remove them in bulk by selecting products and choosing Add tags or Remove tags (Shopify Help Center, Using tags).

Where the tag method breaks

A tag does not know what the price is. Someone has to add it when a product goes on sale and remove it when the sale ends, and both steps fail quietly. Miss the first and codes stack on the markdown. Miss the second and a full-price product refuses codes until a customer complains.

It also breaks whenever prices change with no person in the loop. A scheduled sale, a bulk price import or a rules-based markdown app changes prices without touching tags, unless the tool also tags. Shopify’s tags page says Shopify Flow can “automatically add and remove tags based on triggers and conditions,” and Disco’s listing includes “Auto-tag sale products” on its Professional plan. We have not verified which Flow triggers fire on a compare-at price change, so check before designing around it.

When tags are still the right choice

  • Your compare-at field holds a list price permanently, so it is not a sale signal.
  • The exclusion is not about sale status: new arrivals, low-margin lines, or brands whose terms forbid discounting. For a brand or product type, a Vendor or Type condition does the job without tags.
  • You want one switch for “no codes on this, ever” that staff can apply from the product list.

Many stores will use both: the compare-at condition for sale status, and a no-codes tag in the Exclude section for everything else.

Method 3: Order-level codes and what an amount off orders discount can skip

The code that most often lands on sale items is an order discount, such as a “10% off your first order” welcome code created as Amount off orders. Shopify’s documentation is consistent that this type has no product scope.

  • The amount off discounts page words its Applies to step for product discounts only: “To apply an amount off product discount to specific products or collections…” It describes no equivalent for order discounts.
  • The combinations page defines the class by its target: “Order discounts: Apply to cart subtotals.”
  • shopify.dev removes any doubt: “A native Amount off orders discount applies to the whole order and has no setting that excludes products.”

So the plain answer to whether an order-level code can skip sale items is no. Of the three ways forward, we recommend the first for most stores.

Replace the order code with a product code

Create an Amount off products discount with the same percentage, scope it to the full-price collection, and retire the order code. A customer buying only full-price products pays the same either way. Shopify’s pages do not describe converting one discount type into the other, so plan on creating a new discount.

Two documented things change:

  • The class. It is now a product discount. The combinations page says “product discounts apply first to individual items,” with order discounts applied “to the revised subtotal after product discounts,” and that combining multiple product discounts on the same line item needs Shopify Plus. Review what the new code combines with.
  • Fixed amounts. “$10 off your order” is one deduction. As a product discount, Shopify’s FAQ says a fixed amount code for specific products or variants has “Only apply discount once per order” selected by default; deselect it and “the fixed amount comes off each eligible item in the order.” Leave the default on.

An illustrative mixed cart

Say a cart holds a jacket marked down from $120 to $90 and a full-price shirt at $60, and the customer enters a 15% welcome code.

  • As an amount off orders code, 15% comes off the $150 subtotal: $22.50. The customer pays $127.50, and $13.50 of the discount fell on the jacket that was already 25% off.
  • As an amount off products code scoped to the full-price collection, 15% comes off the shirt only: $9.00. The customer pays $141.00.

The $13.50 difference is what the order-level code cost on this one cart. The other two routes, a blocking app or a custom Function, are Methods 5 and 6.

Method 4: Combination settings and what Shopify discount stacking covers

Merchants looking for a stacking switch usually end up in the Combinations section of the discount form. It is the right tool for a neighbouring problem and no tool at all for this one.

What combinations control

Shopify sorts every discount into a class: product, order or shipping. On each discount you select which classes it may combine with. The combinations page is the rulebook for Shopify discount stacking:

  • Order of application. Product discounts first, order discounts on the revised subtotal, shipping discounts last.
  • How to stack discount codes. “Customers can use a maximum of 5 product or order discount codes and 1 shipping discount code on the same order,” provided each is set to combine with the others’ classes.
  • Automatic discounts. “You can have a maximum of 25 active automatic discounts,” a count that includes app-based discounts.
  • Percentage order discounts. When two combine, “both percentages are calculated on the original subtotal”: 10% and 20% on $100 leaves $70.
  • When discounts cannot combine. Shopify says “the best discount for the customer’s cart is always applied.”
  • Where it works. “Discounts can only be combined on orders that are made through the Online Store, Storefront API, and Shopify POS.”

What combinations do not control

Every rule above is about one discount meeting another. A compare-at sale is not a discount of any class. It is the product’s price, and the combinations page does not mention compare-at prices or sale items anywhere. Unticking every box on your welcome code stops it combining with other discounts. It does nothing about the jacket that is already $90.

Customer eligibility is not a product filter either. The amount off discounts page lets you limit a discount to all customers, specific customers, customer segments or markets, and the managing discounts page allows up to 5 customer segments on a single automatic discount. Those settings decide who may use a discount, not which products it touches. Restricting a code to a segment shrinks the leak without closing it.

The one case where combinations solve it

If the sale itself is a discount, the rules do apply. Run the promotion as an automatic Amount off products discount on a collection, leave its combinations unticked, and a code can no longer stack on it: Shopify applies whichever is better for the cart, not both. We set out how to build and time a sale that way in our guide to scheduling a sale on Shopify.

The trade-off is visibility. An automatic discount applies “in the cart and at checkout,” and Shopify’s FAQ says crossed-out prices on product pages need a third-party app or a Shopify Partner. For a clearance rack, where the strikethrough does the selling, that is usually the wrong trade.

Method 5: Apps with a “block codes on sale items” feature

Several apps advertise this. First, the two ways an app can deliver it, because shopify.dev is specific about what is possible and the difference decides what customers experience.

Rejecting the code. A discount Function can reject a code the customer entered, and shopify.dev sets the limit: “A rejection removes the code from the whole cart. The operation takes codes and a message, and it takes no cart line IDs, so a Function can’t reject a code for one product or one line.” An app working this way cannot apply the code to the shirt and refuse it on the jacket. Shopify’s tutorial adds that “discount rejection operations are only supported for automatic discounts,” so the blocker runs as an automatic app discount (shopify.dev, Build a Discount Function that rejects invalid codes).

Creating its own discount that skips sale lines. shopify.dev also says a Discount Function “can’t change the amount, targets, or settings of a native discount or a discount from another app.” An app can offer a discount type that leaves sale lines out, but only for discounts created inside that app.

The table reports what each App Store listing states, with ratings recorded on 3 December 2026. We have not installed any of these apps, and nothing here is a performance claim. The wider field is in our roundup of Shopify discount apps.

AppWhat the listing states about sale itemsPlan that lists the featureRating, 3 December 2026
Alpha: Sale & Discount Manager“Exclude sale items from discount codes or block leaked codes”Listed from Basic at $9.99/month (100 unique products/month), Pro at $17.99 and Ultimate at $25.99; not on the Free plan. 3-day trial.4.9 (320 reviews)
Disco: Flash Sales & Discounts“Block discount codes on sale items”“Block discount codes” is listed on Business only: $25.99/month after a first month at $19.49. 14-day trial.4.8 (119 reviews)
Regios Automatic DiscountsA flowchart logic builder for nested discount rules on Shopify Functions. No mention of sale items or compare-at prices.Starter $34.99/month for up to 500 discounted orders a month, rising to Scale at $249.99. 7-day trial.4.9 (249 reviews)
DCB – Discount Code BlockerStops codes on “sale items (with a compare-at price)”; “If restricted products are in the cart, codes won’t apply to the whole order”Basic $9/month; a Shopify Plus plan at $19/month adds value-based blocking. 3-day trial.4.8 (8 reviews)
Craftly Discount Rules“Block discount codes on sale items and prevent double discounts automatically”Rejection rules from Professional at $3.99/month (3 active rules) to Master Plus at $14.99 (25); none on the free plan. 7-day trial.5.0 (6 reviews)
Solo Discount“Exclude sale items from discounts — skip variants already on sale”; “checked per variant at checkout”Standard $14.99/month for Basic and Shopify plans; Advanced $39.99/month for Advanced, Plus and Enterprise. 14-day trial.No reviews yet

How to read those listings

  • Alpha and Disco are sale managers first. Both listings describe scheduling sale prices and restoring them afterwards, and both carry the Built for Shopify badge. If you are already choosing a tool to run calendar sales, getting the block from the same app is tidy. On Disco the feature is listed on the top tier only.
  • DCB states the whole-cart behaviour itself, adding that “100% blocking isn’t guaranteed for every discount type combination or custom checkout setup.” That is the honest version of what shopify.dev documents for any rejection-based blocker. Ask the others the same question before installing.
  • Solo Discount’s listing describes the other mechanism: a Shopify Function that checks each variant, for discount codes and automatic discounts. Read against shopify.dev’s rule that a Function controls only the discounts it creates, that points to creating your discounts through the app, not blocking the ones you have. It had no reviews on the date we checked.
  • Regios is here because it is often suggested for the job. Its listing states no sale-item rule, so confirm with the developer that its logic builder can test for a compare-at price before paying for this purpose alone.
  • Apps leave. One blocker still in search results, SDB – On Sale Discount Blocker, showed “This app is not currently available on the Shopify App Store” when we opened its listing.

Method 6: Shopify Functions and custom discount logic

If nothing above fits, the remaining option is to have the discount built. This is the route for a store that needs an order-level discount to skip sale lines precisely, per line.

Who can use it

shopify.dev states availability at the top of its Functions overview: “Stores on any plan can use public apps that are distributed through the Shopify App Store and contain functions. Only stores on a Shopify Plus plan can use custom apps that contain Shopify Function APIs” (shopify.dev, About Shopify Functions). Any store can install an App Store app that uses a discount Function. A private, built-for-you Function needs Shopify Plus and a developer.

What it would do

The Discount Function API passes the cart to your code, and each line’s cost includes its compare-at amount alongside the price charged. Shopify publishes an example for this purpose, “Apply a discount to orders with no sale items,” which gives a discount “to any order whose product variants do not have a compare-at price higher than its current price.” That example is all-or-nothing: one sale line and it returns no discount.

For per-line behaviour, shopify.dev names two levers: “leave the line out of the targets of productDiscountsAdd, or list the line in orderSubtotal.excludedCartLineIds for an order discount.” The second is what native order discounts lack. A custom discount can also compare the two amounts directly, testing “compare-at price is higher than price,” which no collection condition can.

What it cannot do

  • Edit your native discounts. A Function “controls the discounts it creates.” Existing codes need recreating as the custom type, or blocking by rejection with the whole-cart limit.
  • Reject every code. The reference says a Function “can reject only codes that have rejectable: true.”
  • See a hidden compare-at price. The reference notes the compare-at amount “is null when the value is hidden from buyers.”
  • Wait for a better API. shopify.dev records that “the Discounts Allocator Function API preview ended on September 10, 2026, and the API won’t be released” (shopify.dev, About discounts).

The cost is developer time to build it and keep it current. We are not quoting a figure, because it depends on who builds it.

Which method to use: the decision table

MethodProduct codes?Order codes?Automatic discounts?MaintenanceCost
1. Full-price collection on “Compare at price is not set”YesNoYes, amount off productsNone after setup; keep compare-at fields cleanFree
1b. Full-price collection excluding a sale collectionYes, including partial-variant salesNoYes, amount off productsNone; uses one of 5 excluding collectionsFree
2. Tag-based collectionYesNoYes, amount off productsTag and untag at every saleFree
3. Replace the order code with a product codeNot applicableSolved by removing the order codeNot applicableOne-time rebuildFree
4. Combination settingsOnly when the sale is itself a discountOnly when the sale is itself a discountYes, between discountsReview on every new discountFree
5a. Code-blocking appYes; for the whole cart if it works by rejectionYes; for the whole cart if it works by rejectionDepends on the appApp rules and customer messaging$3.99 to $25.99/month across the blocking plans listed above
5b. App discount type that skips sale linesYes, for codes created in the appDepends on the appYes, per the listingRecreate discounts in the app$14.99 to $39.99/month (Solo Discount)
6. Custom discount FunctionYes, for discounts it createsYes, with excluded cart linesYesDeveloper upkeepDevelopment cost; custom apps need Shopify Plus

Our recommendation, in order: build the full-price collection today and point every product-level code at it. Rebuild percentage order codes as product codes on the same collection. Keep a no-codes tag for exclusions unrelated to price. Pay for an app only if you must keep true order-level codes, or codes issued by another system you cannot re-scope, and confirm first whether it blocks per cart or per line.

Where automatic markdowns make this harder

A manual sale has a launch moment, and whoever builds the campaign can remember to pause the welcome code or tag the products. Rules-based markdowns have no such moment, which is the point of them.

Auto Markdown, the app we build, lowers a product’s price by a set percentage after a set number of days without a sale, continues in steps down to a floor price, and restores the original price when a unit sells. Its listing gives the check interval by plan: every 24 hours on Free, every 6 hours on Growth at $9 a month, and hourly on Pro at $19 and Enterprise at $39 (Shopify App Store, Auto MarkDown). A product can go on sale at 3 a.m. on a Tuesday with no one creating anything.

To be plain about our own product: Auto Markdown has no code-blocking feature. It does not create, read, reject or restrict discount codes. If you need one tool that both runs sales and blocks codes on them, the Alpha and Disco listings state both features and ours does not.

What it does do is write the original price to the compare-at field while a product is marked down, which makes the compare-at condition the method that keeps up by itself. A product marked down by rule gains a compare-at price, drops out of the full-price collection, and stops accepting scoped codes with nobody involved. A tag-based collection would need something to add the tag at 3 a.m.

One caution from Method 1 carries over. Auto Markdown’s Growth plan lists variant-level tracking, and a markdown on some variants of a product is the case “is not set” misses. If your rules mark down individual variants, use the stricter construction with the excluded sale collection.

The margin math when a code lands on a sale item

An illustrative example with round numbers: say a store sells a jacket for $120 that costs $48 landed.

ScenarioCustomer paysGross profit per unitGross marginTotal reduction
Full price$120.00$72.0060.0%0%
Marked down 25%$90.00$42.0046.7%25%
Marked down 25%, then a 15% code$76.50$28.5037.3%36.25%

The two percentages do not add to 40%; the code takes 15% of $90, so the combined reduction is 36.25%. The code’s $13.50 is about 32% of the $42.00 of gross profit the markdown had left. And if the lowest acceptable price for that jacket were $80, the markdown respected it and the code went through it. How to set that number is in our clearance floor price guide.

Scale it to judge a paid fix. If, say, 40 orders a month redeem the code on a marked-down item at that $13.50 average, the leak is $540 a month. Hold that against a $9.99 or $25.99 app plan, and against the free collection method that removes most of it. The full comparison of what each discount mechanic costs is in our markdown vs coupon vs bundle framework.

How to audit the codes you already have

New codes are easy to scope. The exposure is in codes created months ago. Shopify’s managing discounts page describes the tools (Shopify Help Center, Managing discounts).

  1. Filter to what is live. The Discounts list filters by Status, Method, Type, Combines with, Start date, Times used, eligibility and Tag. Start with active discounts and review codes and automatic discounts separately.
  2. Pull out the order discounts. Every active amount off orders discount applies to sale items by definition. List them for rebuilding or retirement.
  3. Open each product discount. The page lists no filter for what a discount applies to, so this part is manual. Is Applies to limited to the full-price collection, to collections that also hold sale products, or to everything?
  4. Rank by Times used. A dormant code matters less than a welcome code redeemed daily.
  5. Deactivate what you cannot justify. The page says “you can temporarily deactivate an unexpired discount,” and the FAQ notes that bulk actions can deactivate many codes at once.
  6. Save the view and keep a log. A saved filter view makes the next audit quick. Keep your own notes on changes, because the discount timeline “doesn’t describe the specific edit made.”

Shopify also exports discounts to CSV (Shopify Help Center, Exporting discounts). The page does not list the exported columns, so open the file before assuming it holds the Applies to detail.

Then look outside the Discounts page. Codes generated by other tools, such as loyalty, email or referral apps, are created with whatever scope that tool sets. Find the template in each and check whether its codes can be limited to a collection.

What to tell customers

An exclusion discovered at checkout feels like a broken code. One read beforehand is a condition of the offer. Shopify’s message when a scoped code meets a cart of sale items is generic, so the explanation has to come from you, earlier. Wording to adapt:

Code WELCOME15: 15% off full-price items. Excludes sale items.
Discount codes can't be combined with sale prices.
15% off when you spend $100 on full-price items.

The third line exists because of the minimum rule quoted earlier: with a scoped code only eligible items count toward the threshold, and a bare “spend $100” will produce $140 carts that do not qualify.

Where to put it:

  • Wherever the code is issued: the signup popup, the welcome email, the insert card, the influencer’s brief.
  • On sale product pages and the sale collection, as a short line near the price.
  • In the cart, the last point before the code field.
  • In your discount terms or FAQ page, so support has something to link.

With a blocker app, change the wording to match the whole-cart behaviour: “Codes can’t be used on orders that contain sale items.” DCB’s listing says you can show a custom error message, and Shopify’s rejection tutorial says the message “displays as a warning banner in checkout.” Use it to say what to do next, not only what went wrong.

Testing checklist

Shopify’s combinations page suggests two safe ways to check discount behaviour: place a test order, or build the cart and stop at checkout before paying.

  1. Full-price cart. The code applies at the expected value.
  2. Sale-only cart. The code is refused, with a message you are happy for customers to see.
  3. Mixed cart. A scoped code lands on the full-price lines only. With a blocker app, note whether the code is removed entirely.
  4. Partial-variant product. Put one variant on sale, add it to the cart, and try the code. This shows whether you need the stricter collection.
  5. Minimum threshold. A cart that passes the minimum only when sale items are counted should not qualify.
  6. A fresh markdown. Add a compare-at price to a product, confirm it has left the full-price collection, then reverse it and confirm it returns.
  7. Code plus automatic discount. The pair combines, or does not, as your settings intend.
  8. Other channels. Shopify’s FAQ says “you can’t restrict customers from redeeming discount codes on specific sales channels,” so test POS and any other channel you sell on.

Common mistakes

  1. Looking for the setting in Combinations. Those checkboxes decide whether a discount stacks with other discounts. A compare-at sale is a price, and no box there affects it.
  2. Leaving the welcome code as an amount off orders discount. It has no product scope and cannot be given one. Rebuild it as a product discount on the full-price collection.
  3. Using “is not set” while running sales on single variants. The condition matches when any variant has an empty compare-at price, so a product with one marked-down size stays eligible.
  4. Typing 0 to clear a compare-at price. Shopify’s conditions page says $0.00 “isn’t considered empty.” Empty the field.
  5. Adding a second collection to the discount “to be safe.” The discount applies to products in any collection you add, so one that also contains sale products undoes the scope.
  6. Relying on tags without an untag step. The sale ends, the tag stays, and a full-price product refuses codes until someone notices.
  7. Installing a blocker without changing the customer message. A rejection removes the code from the whole cart. Customers expecting 15% off their full-price items need to hear that before checkout tells them.

FAQ

Can you exclude sale items from a discount code on Shopify?

Not with a dedicated setting. Shopify’s documentation does not describe an “exclude sale items” option on discounts. The documented route is to create an Amount off products discount, set Applies to as Specific collections, and add a collection of full-price products built on the condition Compare at price is not set. Products leave that collection when every variant has a compare-at price, and the code stops applying to them.

How do I exclude specific products from a discount code in Shopify?

Shopify discounts are defined by what they include, so you exclude a product by leaving it out. Build a collection of the products the code should cover, using conditions or a tag such as no-codes in the collection’s Exclude section, then limit the discount to that collection under Applies to. A code can list at most 100 specific customers, products and variants, which is why a collection scales better than a product list.

Does a Shopify discount code apply to sale items?

Yes, unless the discount is scoped away from them. Shopify’s sale pricing page says only the sale price is displayed at checkout, and discounts are calculated from that price. A 15% code on a product marked down from $120 to $90 brings it to $76.50, a 36.25% total reduction. The same holds for automatic discounts: the compare-at price plays no part in whether a discount applies.

Can I stop discount stacking on Shopify without an app?

For product-level codes and automatic discounts, yes: scope them to a full-price collection built on the compare-at price condition. For stacking between two discounts, use the Combinations section on each discount. The case with no native fix is an amount off orders code, which applies to the whole order; replace it with a product discount or use an app.

Can an amount off order discount exclude sale items?

No. Shopify’s developer documentation states that a native Amount off orders discount applies to the whole order and has no setting that excludes products. You can recreate the offer as an Amount off products discount limited to a full-price collection, install an app that rejects the code when sale items are in the cart, which removes it from the entire order, or have a custom discount built with Shopify Functions.

How do I stack discount codes on Shopify?

Open each discount and, in its Combinations section, select the classes it may combine with: product, order or shipping. Shopify allows up to 5 product or order discount codes and 1 shipping discount code on one order. Combining several product discounts on the same line item requires Shopify Plus, and when codes cannot combine, Shopify applies the best one for the cart.

Does Auto Markdown stop discount codes applying to marked-down products?

No. Auto Markdown has no code-blocking feature and does not manage discount codes at all. It lowers prices by rule and sets the compare-at price to the original while a product is marked down. That compare-at value is what removes the product from a full-price collection built on the Compare at price condition, so codes scoped to that collection stop applying without a manual step.


— Palm Beach Themes is a Miami-based Shopify app studio. We build the apps we write about, and we link every claim to its source.

If the sale items you are protecting are slow sellers that should have been marked down weeks ago, Auto Markdown handles that half: rules-based markdowns with a floor price, the original price kept in the compare-at field, and prices restored when the product sells. It will not block a discount code, so pair it with the full-price collection from Method 1. The free plan tracks 50 products, enough to try the pairing on one collection.