Auto add product to cart
Last updated
Last updated
This guide will walk you through how you can setup auto product add to cart based on the coupon code.
You need to have Dollarlabs: Ultimate discounts app installed
You need to have checkout extensibility enabled on your store.
The checkout block discount-auto-add-item
needs to be added to your checkout.
The block does not add any visual component to the checkout and is required purely for the add to cart logic to function.
This feature should only be used to add products to the cart that do not increase the total order value of the cart. Ensure compliance with Shopify's app requirements and is only available to use for Shopify Plus merchants due to limtiations.
Head over to Shopify admin > Settings > Checkout > Customize
Click + Add app block
anywhere on the checkout customization pane and add the discount-auto-add-item
block from the dropdown.
Enter in exactly the discount code (case-sensitive) for which the product should be auto added to cart and then pick the products using the select variant
button and then hit save.
Test out the behavior on your checkout by entering the coupon code in the cart. The product should be automatically added and removed based on the discount code application.
You can also use wildcard character "*" to do partial matches like first X characters. This is super helpful when you want to combine this feature with bulk code generation.