How to show the quantity of items left, including each variance?

Hi! I have Taste theme, but for some of my products theres 1-20 items and i realized it doesn’t show how many are left, so if a customer wanted to add multiple they’d have to up the quantity, then click add to cart then if it says too much, go down one, try again, etc etc.

Seems like there should be an easy way to show the stock of each item on the product page, preferably also for each variant, but all I can find is one super annoying app that has a progress bar and says “X Items left” but that also doesn’t show per variant?

thanks!

Hi @griffinmalone ,

Please go to Actions > Edit code > Sections > main-product.liquid file, find ‘price’ and add code here:

Code:

{%- if product.selected_or_first_available_variant.inventory_quantity > 0 -%}
                

{{ product.selected_or_first_available_variant.inventory_quantity }} items left

{%- endif -%}

Hope it helps!

You’re THE BEST! Thank you!!!

1 Like