🔎Displaying Star Ratings on Organic Google Search Results

You can manually add the code by following the steps below:
You can verify the integration using Google's structured data testing tool. For products with at least one review, you should see an "aggregateRating" section under the Product object:
Create a new snippet called
wise-rich-snippet.liquid
undersnippets
folder.

Paste the following code.
{% capture productID %}{{ product.id }}{% endcapture %}
{% if shop.metafields.wisereviews.reviews.value.products[productID].average_rating %}
<script id="wiseReviewsSchemaJson" type="application/ld+json">
{
"@context": "http://schema.org",
"@type": "Product",
"@id": {{ canonical_url | json }},
"aggregateRating": {
"@type": "AggregateRating",
"ratingValue": "{{ shop.metafields.wisereviews.reviews.value.products[productID].average_rating }}",
"reviewCount": "{{ shop.metafields.wisereviews.reviews.value.products[productID].reviews_count }}"
},
"name": {{ product.title | json }}
}
</script>
{% endif %}
Open the template or section you use for product pages (usually called product.liquid, main-product.liquid or product-template.liquid, but some themes may work differently).
{% render 'wise-rich-snippet', product: product %}
Paste the following code at the bottom of the page:

Last updated