# Display star rating for each product in the product list

1. Go to admin page > Sales channels > Online store > Themes.

<figure><img src="/files/LxOK9iFDmARKEYmotiXD" alt=""><figcaption></figcaption></figure>

2. Select the theme you want to display the Review widget > Edit code.

<figure><img src="/files/MnhvB1Z6oUBvZolutw7A" alt=""><figcaption></figcaption></figure>

3. In theme editor, open file  *Snippets/card-product.liquid*

<figure><img src="/files/CV238xHFGH7O6q0DBsjU" alt=""><figcaption></figcaption></figure>

4. Add code to the file *Snippets/card-product.liquid*

Copy the code below:&#x20;

```html
<div class="rh-rv-prod-featured" data-id="{{ card_product.id }}" data-avg-rating="{{ card_product.metafields.ratifyhub.widget.avg }}" data-total-rating="{{ card_product.metafields.ratifyhub.widget.total }}"></div>
```

Find the line with the same or similar code:  `{% render 'price', product: card_product, price_class: '' %}`  and paste the copied code above it.

<figure><img src="/files/JItyvFiS1sBZwlstL6hw" alt=""><figcaption></figcaption></figure>

5. Save the changes.

<figure><img src="/files/HQepQukbtIGA94RSexsE" alt=""><figcaption></figcaption></figure>

6. Go to customize theme.

<figure><img src="/files/E4Uqp9dlAFkSgiFGRwdk" alt=""><figcaption></figcaption></figure>

7. Select App embed > Enable "Review app code" > Save

<figure><img src="/files/Tu07NSgHiRxn4VGP9Ydr" alt=""><figcaption></figcaption></figure>

8. The results.

<figure><img src="/files/QD7HtN2PqgHkwnhpWNXv" alt=""><figcaption></figcaption></figure>


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.ratifyhub.com/display-star-rating-for-each-product-in-the-product-list.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
