Supply Theme Show Price range of Variants on Collections page

I have multiple size variants of a particular product which have different prices and I would like the collection page to show that price range instead of the lowest price variant price. Thanks in advance for the help

Hello @kopetski7 ,

Welcome to the Shopify community!
and Thanks for your Good question.

Please share your site URL,
So I will check and provide a solution here.

Hi there

Line 76 in the product-grid-item.liquid Snippet.

{% include 'price' with product.price %}

Change that for:

{% include 'price' with product.price_min %} - {% include 'price' with product.price_max %}

That should get you to somewhere near what you need?

Thanks for helping! I edited the code and it worked however now all the products that don’t have variants show price-price (so 25.99- 25.99) instead of just the one price. Any ideas how to edit and fix ? Thanks again

@kopetski7 , Try this

{% if  product.price_varies %}
  {% include 'price' with product.price_min %} - {% include 'price' with product.price_max %}
{% else %}
 {% include 'price' with product.price %}
{% endif %}

if useful please mark as like and accept the solution

3 Likes

This removed the price from the non variant ones. variant ones are correct, but no price is shown for ones with no variant.

Ok think I figured it out just added another else statement

{% if product.price_varies %} {% include ‘price’ with product.price_min %} - {% include ‘price’ with product.price_max %}
{% else %}
{% include ‘price’ with product.price %}
{% endif %}

Thank you for your Help!!

2 Likes

Hi, the same worked for me. Thank you a lot.

But now I also want the price range of variant products to show on the search results page too…Any help will be appreciated.

Thank you.

@kopetski7,

@Wahab_Ahmad , @kopetski7,

Hi, the same solution you provided worked for me. Thank you a lot.

But now I also want the price range of variant products to show on the search results page too…Any help will be appreciated.

Thank you.

Any idea why when I add this that some of the variant ranges show, but not all of them?

Hi @kopetski7 , learn to easily display variant details on Shopify collection pages by watching this tutorial:

https://youtu.be/Z7As6ia4wPI?si=w9P60NfPFZwww8wy