HomeProjectsServicesContactGuides
← all guides

Scripts are gone. Here is what runs your discounts now.

topicShopify development
read time11 min
publishedSep 2026
Shopify Functions and native discounts
TL;DR

Shopify Scripts stopped executing on June 30, 2026, after two extensions, and editing was locked from April 15. Any store that missed it saw its custom discount, shipping and payment logic silently revert to Shopify's defaults. The replacement is two things, not one: native discounts in the admin, which now cover far more than most founders assume, and Shopify Functions, server-side code that runs inside checkout for the cases native cannot express. The catch that matters for standard-plan stores: apps from the App Store that use Functions work on every plan, but a custom Function app built just for your store requires Shopify Plus. Plan the discount logic around that line before anyone quotes you for it.

What actually happened on June 30

Shopify Scripts were the Ruby snippets Plus stores used to bend checkout: tiered discounts, hiding a payment method for certain customers, reordering shipping rates. Shopify announced the retirement in 2023, pushed the date twice, and then held the line: editing locked on April 15, 2026, execution stopped on June 30, 2026. There is no extension this time and no way to re-enable them.

If your store was on Plus and had Scripts, one of two things is true today. Either they were rebuilt on Checkout Extensibility before the deadline, or your checkout has been quietly running on defaults since July 1. The second case is more common than it should be, because nothing errors. A "buy three, get 15% off" rule simply stops applying, and the first person to notice is usually a customer, or your margin report.

If you were never on Plus, none of this touched you directly, but it changed the landscape you are buying apps in. Every discount and bundle app in the App Store has spent the last two years moving to Functions, and the ones that did not are the ones to leave.

Start with native discounts, because they cover more than you think

Before anyone writes code, check whether the admin already does what you want. In 2026 the native discount system handles:

  • Amount off products, amount off order, buy X get Y, and free shipping, each as a code or as an automatic discount that needs no code at all.
  • Combinations. Product, order and shipping discounts can be set to combine with each other, so a welcome code and a free-shipping threshold can stack without an app in the middle.
  • Tiered thresholds such as 10% off over ₹2,000 and 15% off over ₹4,000, expressed as separate automatic discounts with minimum purchase requirements.
  • Eligibility by customer segment, so a discount can apply only to first-time buyers, only to a tag, or only to a segment you have built in the admin.
  • Scheduling with start and end dates, and usage limits per code and per customer.

There are ceilings. Shopify caps the number of automatic discounts that can be active at once (25 at time of writing) and limits how many apply to a single order, and native cannot do anything conditional on cart composition beyond quantity and value, such as "free gift only if the cart contains a full-size product and no samples". Those are the cases that were Scripts, and are now Functions.

What a Function is, in one paragraph

A Shopify Function is a small program, compiled to WebAssembly, that Shopify runs on its own servers at the moment checkout calculates something. It receives the cart as input and returns a result: a set of discounts to apply, a list of shipping rates to hide or rename, a payment method to remove, a reason to block checkout, or a transformed cart where three items have become one bundle. It runs in a few milliseconds, it cannot make network calls, and it cannot touch the storefront. That last part is the point: Functions replace cart-level JavaScript that used to sit in your theme, which is why they matter for INP as much as for margin.

The Function APIs that cover what Scripts used to do:

  • Discount. Since API version 2025-04 one Discount Function handles product, order and shipping discount classes together, replacing the three separate APIs that came before it. This is where tiered, conditional and gift-with-purchase logic lives.
  • Cart transform. Bundles and expanding a kit SKU into its components at checkout, so inventory is deducted correctly.
  • Delivery customization. Hide, rename or reorder shipping rates based on the cart, the address or the customer.
  • Payment customization. Hide or reorder payment methods. The Indian use: hide cash on delivery for pincodes or customers where your RTO history says it will not convert into a delivery.
  • Validation. Block checkout with a message when a rule is broken, such as a quantity cap per customer on a launch drop.
  • Fulfilment constraints and pickup points, for stores with several locations or a click-and-collect model.

The plan gate that decides your options

This is the sentence to read twice. Shopify's own documentation: stores on any plan can use public apps distributed through the App Store that contain Functions, but only stores on a Shopify Plus plan can use custom apps that contain Functions.

In practice that gives a standard-plan store three routes, in order of cost:

  • Native discounts. Free, no code, and enough for most promotional calendars.
  • An App Store app built on Functions. Bundle builders, tiered-discount apps, free-gift apps and COD-hiding apps all exist in this form. You are paying a subscription for someone else's Function plus a configuration UI. Check that the app is actually Functions-based and not injecting a cart script; the app audit shows how.
  • A custom Function for exactly your rule. Requires Plus. If the rule is the thing your business model depends on, this is one more line in the Plus decision, not a reason on its own.

The same gate applies to checkout UI: extensions that change what the checkout page shows during the information, shipping and payment steps are Plus-only, while extensions on the thank-you and order status pages work on every plan.

Migrating a discount rulebook, in the right order

  • Write down every rule the old setup enforced, from the Scripts code, the discount app settings, and the promotions calendar. Include the ones nobody remembers switching on. The purpose of this list is to find out which rules still earn their place.
  • Kill rules that no longer pay. A stacking rule from a 2023 campaign does not need to survive a rebuild. Most rulebooks lose a third of their entries here.
  • Map what remains to native first, then to an app, then to custom. Be honest about "native with a small compromise" versus "custom for the exact behaviour": the compromise is usually cheaper than the ongoing maintenance.
  • Rebuild on a development store or a duplicate and test with real cart shapes: mixed carts, discount codes stacked on automatic discounts, a B2B customer, a subscription line. Discount bugs live in the combinations.
  • Retire the old app the same week you switch. Two discount engines fighting over one cart produces double discounts, and you will only find out when the finance reconciliation runs.
  • Put the rules in writing where the next developer can find them. Scripts were at least visible in one place. Functions in three apps plus native automatic discounts are not.

Common mistakes

  • Assuming a "Plus feature" is out of reach. The rule you want is probably an App Store app on any plan. Ask before scoping a Plus upgrade around it.
  • Keeping a JavaScript cart-discount app because it "works". It works by rewriting prices in the browser after checkout has already calculated them, which is why the numbers disagree in your reports and why your INP is bad.
  • Testing only the happy path. One product, one code. The bug is in the cart with a gift card, a subscription and a stacked code.
  • Not checking what defaulted on July 1. If you were on Plus with Scripts, pull the discount lines on orders from the first week of July and compare them to June. Silent reverts leave a signature.

FAQ

Are Shopify Scripts still running?

No. Shopify Scripts stopped executing on June 30, 2026, after editing was locked on April 15, 2026. The date had been extended twice before and Shopify held this one. Any checkout logic that was still on Scripts reverted silently to Shopify's default behaviour from July 1, and it cannot be re-enabled. The replacement is Checkout Extensibility: native discounts for the common cases and Shopify Functions for custom logic.

Do I need Shopify Plus to use Shopify Functions?

It depends on where the Function comes from. Apps distributed through the Shopify App Store that are built on Functions work on every plan. A custom app containing Functions, built just for your store, can only be installed on a Shopify Plus store. For a standard-plan store the practical order is native discounts first, then an App Store app built on Functions, and a custom Function only if the rule justifies a Plus upgrade.

What can native Shopify discounts do without any app?

Amount off products, amount off order, buy X get Y and free shipping, as codes or as automatic discounts, with minimum purchase requirements, customer segment eligibility, scheduling and usage limits. Product, order and shipping discounts can be set to combine. What native cannot express is logic conditional on cart composition beyond quantity and value, such as a free gift only when a specific product is present and another is absent. Those cases need a Function.

What is the difference between a Shopify Function and a checkout UI extension?

A Function changes what checkout computes: which discounts apply, which shipping rates or payment methods appear, whether checkout is allowed, how the cart is structured. A checkout UI extension changes what the checkout page shows, such as a custom banner or a field. Functions run on Shopify's servers with no storefront code. UI extensions on the information, shipping and payment steps require Plus; extensions on the thank-you and order status pages work on all plans.

How do I know if my store lost discount logic when Scripts stopped?

Compare discount lines on orders from the first week of July 2026 against the last week of June. A tiered or conditional discount that stopped applying shows up as a step change in average discount per order. Also check the Scripts section in the admin: if it lists scripts that were never rebuilt, that logic is not running anywhere now.

Should I keep my current discount or bundle app after moving to Functions?

Keep it only if it is built on Functions and does something native discounts cannot. Apps that apply discounts by rewriting prices in the browser should go: they disagree with checkout's own calculation, produce mismatched reports and slow the storefront. Whatever you keep, retire the replaced app in the same week you enable the new logic so two engines never apply to the same cart.

More guides

Contact us

Let's build something amazing, together.

Bring the brief. We'll bring the build, the speed and the follow-through.