I want to show products quantity (how much product left for single item) in my store front page. Anyone can help?

Highlighted
Shopify Partner
3 0 0

Hi everyone,

I want to show products quantity (how much product left for single item) in my store-front page, not the product page. Could you please help me to fix it. I am using Testament theme. 

I attached an image, I want like that to show 1 left in below.

Below link of the example image

https://imgur.com/Qh3nvTs

 

 

0 Likes
Highlighted
Shopify Partner
1445 195 523

On your product.liquid you can use this output wherever you want to put it:

{{ product.selected_or_first_available_variant.inventory_quantity }} Left

 

If my solution helped you, please like and accept as solution!
If you'd like to make any edits to your store, please send me a personal message and we can discuss what you'd like to accomplish :D
0 Likes
Highlighted
Shopify Partner
3 0 0

Hi Ninthony, This is great! It's working properly. Thanks for your help.

0 Likes
Highlighted
New Member
1 0 0

Thank you for this code @Ninthony , it is working well on our store as well! The only issue we are having is that the quantities of any products with multiple variants do not update unless the page is refreshed. Is there a solution for this? Thank you!

0 Likes
Highlighted
New Member
1 0 0

Hi, 

If we have multiple variants and want to show quantities left per variant (when you select a variant) what would be the code to add?

Using Testament too.

Best regards,

0 Likes