Workaround: Breaking down bundles at the cart level when using Recharge and other subscription apps with Simple Bundles 2.0

Overview

This guide explains how to setup Simple Bundles 2.0 to work with subscription apps such as Recharge and Ordergroove. For more details about this setup and how it works, you can learn more here: Creating bundles with a subscription plan like Recharge, Seal, and Appstle in Simple Bundles 2.0.

Simple Bundles 2.0 uses Shopify’s Cart Transform API to break down bundles into their child components at checkout. While this works well for standard (one-time) purchases, subscription apps require that individual child products, with the selling plan attached, be in the cart before checkout to process recurring orders properly.

Because Cart Transform runs during checkout and removes the parent bundle at that stage, the child products may not retain the selling plan in a way that subscription apps can process correctly. As a result, subscription bundle purchases may trigger the fallback order editing method.

This guide introduces a workaround that expands subscription bundles at the add-to-cart stage when a selling plan is selected. This ensures the subscription app receives the individual child products with the selling plan properly attached.

By the end of this guide, you’ll be able to set up subscription bundles that process correctly at checkout and integrate smoothly with your subscription app.

How it works

When a customer adds a bundle to their cart with a subscription selected, the script performs the following actions:

  • Detects that the product is a bundle and includes a selling plan
  • Reads the bundle’s component data from metafields
  • Expands the bundle into its individual child products
  • Attaches the selected selling plan to each child product
  • Adds the child products to the cart instead of the parent bundle
  • Redirects the customer to the cart page

This script activates only when both conditions are met:

  • The product is a bundle (has bundle metafields)
  • A selling plan (subscription) is selected
  • Child products must be enrolled in the same selling plans as the bundle parent

Non-subscription bundle purchases continue to work normally, with Cart Transform handling the breakdown at checkout. One-time bundle purchases follow the standard Simple Bundles flow without any changes. Regular (non-bundle) products are completely unaffected and will continue to function as usual.

Supported bundle types

This solution works with:

  • Simple Bundles (predefined child products)
  • Infinite Options Bundles (customer-selected options)

How to set it up

To implement this solution, please follow the steps below.

Step 1: Download the required files

Before getting started, download the following files provided with this guide:

Make sure these files are saved locally so they can be uploaded to your Shopify theme.

Step 2: Upload the files to your theme

  1. In your Shopify admin, go to Online Store > Themes.
  2. Click Edit code on your active theme.
Online store theme

Then upload the files to the correct locations:

  • Add simple-bundles-metafields.liquid to your Snippets folder.
  • Add simple-bundles-cart-expander.js to your Assets folder.
Snippets Folder
Assets folder

Step 3: Include the files in your theme

After uploading both files, you’ll need to include them in your theme so they load properly.

In layout/theme.liquid (recommended) or within your product template file, add the following code just before the closing </body>      tag:

{% render 'simple-bundles-metafields' %} {{ 'simple-bundles-cart-expander.js' | asset_url | script_tag }}

This ensures the bundle metafield data is available and the cart expander script runs correctly when a subscription bundle is added to the cart.

Once added, save your changes and test a subscription bundle to confirm it expands properly before checkout.

Cart and order display overview

Bundle product detail page
The bundle will breakdown in the cart
Order with the bundle broken down at the cart level

Troubleshooting

Bundle Not Expanding

  • If the bundle is not expanding, verify that the variant has bundle metafields by running SBExpanderDebug.checkVariant('VARIANT_ID')      in your browser console. Check that the Liquid snippet is rendering correctly on the page and confirm that a selling plan (subscription) is selected before adding the bundle to the cart.

Child Products Not Being Added

  • Ensure that the child products are enrolled in the same selling plans as the bundle. You can also check your browser’s Network tab and review the add.js      response for any errors when the product is added to cart.

Cart Not Updating or No Redirect

  • Different themes handle cart updates differently. The current script redirects customers to /cart      after adding the expanded items. If your theme uses a cart drawer or custom cart behavior, the script may need to be adjusted to match your theme’s setup.

Support

If you encounter any issues or need the script customized for your theme, please contact our support team at hello@simplebundles.io.

Still need help? Contact Us Contact Us