Skip to content

Shopify Dude Fix

Why Shopify Cart Transform Fails on Subscription Lines With Selling Plans

Cart Transform can update or bundle ordinary cart lines, but Shopify rejects lineExpand, linesMerge, and lineUpdate when a selling plan is present. Design subscription pricing and bundles accordingly.

Quick answer: Do not depend on Cart Transform lineExpand, linesMerge, or lineUpdate for a cart line with a selling plan. Shopify’s current Cart Transform compatibility documentation says those operations are rejected when a selling plan is present. A subscription line that looks correct in the theme can therefore behave differently at checkout.
On this page

Why a working one-time purchase breaks on Subscribe & Save

Cart Transform can change line presentation, merge or expand bundles, and update eligible line pricing. But selling-plan lines have compatibility restrictions. Adding a subscription selling plan to the same variant changes the supported operation set. The issue is not necessarily a bad Liquid condition or missing JavaScript cart refresh; Shopify can reject the transform operation itself.

There is a separate availability limit: lineUpdate requires Shopify Plus or a development store. Do not assume a test that succeeds in a development environment proves the same feature is available on a non-Plus production store.

Choose the right layer for the requirement

  1. Subscription price: use the selling plan’s supported pricing configuration and subscription-app integration rather than trying to force a Cart Transform price override.
  2. Promotional discount: evaluate the Discount Function API and subscription compatibility for the exact discount class and checkout scenario. Test for double discounts with selling-plan pricing.
  3. Bundle presentation: if expansion or merging is required, determine whether the bundle is compatible with selling plans before committing to the architecture.
  4. Theme display: Liquid and JavaScript can display prices and labels, but changing displayed HTML does not change the authoritative checkout price.
  5. Checkout behavior: compare one-time and subscription carts independently. Do not treat them as one test case.

Example: build a compatibility matrix before coding

Cart scenario What to verify
One-time variant, no selling plan Eligible Cart Transform operation and final checkout total
Same variant with selling plan Whether Shopify rejects the operation; selling-plan price and discount result
Mixed one-time and subscription cart Untransformed subscription lines and correctly transformed eligible lines
Non-Plus production store Whether the desired lineUpdate operation is available at all

Log your Function input and output in a controlled development environment, keeping customer data out of logs. If a selling plan is present, return only operations the API supports for that cart. Do not invent a fallback line price in the theme and assume checkout will follow it.

Common misunderstanding: “Cart Transform is the universal way to change any cart price, including subscriptions.” Cart Transform has specific operation, plan, and surface restrictions. A selling-plan discount or subscription-app price is not interchangeable with a cart line update.
How to test this

  1. Prepare the same product as a one-time purchase and with a selling plan.
  2. Run each through cart, accelerated checkout where applicable, and standard checkout; record the final line and order totals.
  3. Inspect Cart Transform execution diagnostics for rejected operations rather than trusting the storefront display.
  4. Test a mixed cart with both selling-plan and ordinary lines.
  5. Test the actual production plan eligibility for lineUpdate, not only a development store.
  6. Confirm the subscription contract and later recurring orders have the intended pricing; recurring subscription orders are not a supported Cart Transform surface.
  7. Check for stacking with automatic discounts and subscription discounts before rollout.