anybody can suggest me that how can i display the left quantity in stock of a particular product in product details page ?. I am using Magento 2.1.3.

1 Answer 1


If you want for all products then you can use Only X left Threshold Configuration option from Store > Configuration > Catalog > Inventory. If you set the Qty 20 and If your product Qty is less than 20 then in product detail page It will display like this,

enter image description here

  • How to show this in product list page? Commented Sep 11, 2018 at 12:26
  • This doesn't work for configurable products. How to make it work for configurable products also. Commented Apr 30, 2019 at 5:08

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.