A Shopify store owner encountered an issue where customers could add more items to their cart than available inventory, despite receiving a generic error message that didn’t specify the actual stock quantity.
Initial Solutions Provided:
Verify inventory tracking is enabled in Shopify Admin > Products > Inventory
Ensure “Continue selling when out of stock” is unchecked
Add an inventory quantity display block to the product template (available in Dawn theme)
Technical Fix (Dawn/Studio Themes):
A working solution involves editing the main-product.liquid file in the theme’s sections folder by adding max attributes to the quantity-input element:
i tried this and it seems to somewhat work, but I can change the text inside the quantity selector once, and then it gets deactivated. Any help would be much appreciated:)
This does not seem to work correctly when I have variants with different stock… works good until I start changing variants, or change to a variant that is out of stock
Hi, I have the same issue, but I’m using the Savor theme. How can I prevent customers from adding more of one item to the cart that exceeds the quantity on hand, and how can I display the exact quantity on hand to the customer?