Buying Guide · 2026-12-01
How to choose Shopify Functions: the checks that matter before you commit
Choose in this order. First, check whether native Shopify features already do it, because basic discounts, buy X get Y, and free shipping rules cover more than most briefs admit. Second, check whether a public app's Function does it, since that works on any plan and someone else maintains it. Third, commission a custom Function, knowing custom apps with Functions need Plus and the instruction budget will shape the design. Most stores that jump to step three had a step one answer.
Check the operation set before anything else
Every Function API has a closed list of operations. Discounts can be applied in product, order, and shipping classes. Delivery options can be hidden, renamed, and reordered, not created. Payment methods can be hidden, renamed, and reordered. If your requirement is outside the list, the project is dead no matter who builds it, and finding that out takes ten minutes in the documentation.
Write the requirement as operations before talking to any vendor: hide this rate when the cart weighs over 50 kg, block checkout when a restricted item ships to this state. Vague requirements get quoted as features and delivered as surprises.
Count the store limits
A store can run at most 25 active discount Functions, and similar caps apply to delivery customization, payment customization, and validation, each at 25 active functions. One cart transform function per app, though several apps can each run one. Stores that install apps casually accumulate functions they forgot about, all executing on every cart update.
Audit what is already running before adding more. Two apps both managing discounts can interact through Shopify's combination rules in ways neither vendor tested, and the symptom is a customer screenshot of a discount that should not exist.
Test the failure mode, not just the rule
When a function exceeds its instruction budget or errors, Shopify applies default behaviour. For a discount that means no discount, which costs margin goodwill. For a validation that means the restricted order sails through, which can cost a compliance problem. Know which default your use case falls into before you rely on it.
Test with your largest real carts, not demo carts. Instruction counts scale with cart lines, up to the 200-line reference point, and the store with the 180-line wholesale order is exactly the store whose function gets cancelled at the worst moment.
Related reading
For the background behind “How to choose Shopify Functions: the checks that matter before you commit”, these earlier guides help: Grading Refurbished Stock Honestly: The Disclosure That Stops the Second Return, Box-Free Label-Free Returns: What the QR Code Drop-Off Changes in Your Cost Stack, and Grading Returned Apparel: A, B, and C Rules Your Team Can Actually Use.
Frequently asked questions
Should I build a custom Function or use an app?
Use an app if one covers the rule, and check native discounts first. Custom Functions ship in custom apps, which require Shopify Plus, and you own the maintenance. Build custom only when the rule is genuinely yours and the operation set supports it.
How many Functions can a store run?
Up to 25 active functions per API family for discounts, delivery customization, payment customization, and validation. Cart transform is one function per app, though multiple apps can each contribute one.
What happens when a Function fails or runs too long?
Shopify cancels it and applies default behaviour: no discount, all payment methods shown, unfiltered delivery options, or a validation that does not block. Design knowing which default you will get.
Can a Function create a new shipping rate?
No. Delivery Customization can hide, rename, and reorder rates that already exist from your zones or a carrier service. Creating rates is a carrier service's job, not a Function's.