Missing field "aggregateRating"

Solved
evergreengolfer
Tourist
11 0 1

Having an issue with my Shopify store when looking at the Google search console. On Google I get an error Missing field "aggregateRating" that affects four of my items. Not sure how to resolve this issue. 

AlexHodzitsky
Shopify Partner
70 19 26

Hi evergreengolfer! Hope you are doing well!

This field is responsible for the average rating of the product, you can see more information here -> https://schema.org/AggregateRating. Basically, the app responsible for the review already specify this field by default. What App do you use for product reviews? Can you provide a link to your store and the problematic product in general?

Alex

I didn't choose the Shopify, the Shopify chose me.
Linkedin: alex-hodzitsky
0 Likes
evergreengolfer
Tourist
11 0 1

Alex, 

Thanks for the quick response. The app we use for product reviews is the Product Reviews app from Shopify. I've provided a link to my store zipr.com and screens hotted the problematic links below. Thanks. 

 

Screen Shot 2021-05-06 at 1.17.04 PM.png

0 Likes
AlexHodzitsky
Shopify Partner
70 19 26

This is an accepted solution.

In general, the aggregate review field is added on your store, it just supposedly duplicates the product, and does not add information to the main one. And in this app, this is a problem that everyone faced.

The problem should be solved if you add such a piece of code to the sections/product-template.liquid file somewhere near the output of the product title:

Click to expand...
{%- assign review_rating = false -%}
{% if product.metafields.spr.reviews %}
  {% capture review_data %}{{ product.metafields.spr.reviews }}{% endcapture %}

  {%- assign rating_keyword = '"ratingValue":' -%}
  {%- assign rd_a1 = review_data | split: rating_keyword -%}
  {%- assign rd_a2 = rd_a1[1] | split: "," -%}
  {%- assign rd_a3 = rd_a2[0] | replace: '"', "" -%}
  {%- assign review_rating = rd_a3 | plus: 1 | minus: 1 -%}

  {%- assign count_keyword = '"reviewCount":' -%}
  {%- assign rd_a1 = review_data | split: count_keyword -%}
  {%- assign rd_a2 = rd_a1[1] | split: "," -%}
  {%- assign rd_a3 = rd_a2[0] | replace: '"', "" -%}
  {%- assign review_count = rd_a3 | plus: 1 | minus: 1 -%}
{% endif %}

{%- if review_rating %}
  <div itemprop="aggregateRating" itemscope="" itemtype="https://schema.org/AggregateRating">
    <meta itemprop="ratingValue" content="{{ review_rating }}">
    <meta itemprop="reviewCount" content="{{ review_count }}">
  </div>
{%- endif -%}

Hope this helps.

Alex

I didn't choose the Shopify, the Shopify chose me.
Linkedin: alex-hodzitsky
0 Likes
evergreengolfer
Tourist
11 0 1

Alex. 

 

I tired copying the code and pasting it into the sections/product-template.liquid and when re-running the Google search console am still encountering the same issue, Missing field "aggregateRating".

0 Likes
evergreengolfer
Tourist
11 0 1

Still quite confused on a solution to the issue, have look around the discussion board to look at similar issues, and have found that I am unable to fully understand a solution to the ones that I have looked up. Any help would be highly appreciated, thanks. 

0 Likes
evergreengolfer
Tourist
11 0 1

Still having issues on this and wanted to open it up to all on Shopify for help if possible. 

0 Likes
KieranR
Shopify Partner
257 22 77

@evergreengolfer this is a theme implementation issue which will be specific to your unique store, theme, config and likely require at least a bit of hands-on time to get it working correctly. Try Shopify support you may get lucky which could work out, but I wouldn't hold my breath - as I'd see this as one of those things that's "out of scope" for them to fix.

The simple answer is that to fix it - add aggregateRating field. 

The longer answer is that the actual technical implementation to add that will depend on: 

  • is your theme or existing customizations around schema
  • any apps that are generating schema
  • any GTM code or any JS that is generating schema
  • do you have multiple types of schema like Metadata and JSON-LD? 

In most cases I find the quickest fix to get a good (and working!) schema setup is to dig into the theme, read the code and understand what's going on in context, maybe quick crawl a few pages on ScreamingFrog and check what's happening, then surgically remove out any schema without breaking stuff. Then replace with an app like JSON‑LD for SEO or Schema Plus for SEO and set it to pull review data from Shopify Product Reviews (SPR). If you already have a good handle on HTML, JSON, Liquid etc, it's not technically difficult to write your own schema/JSON code to do this yourself, or tweak your own theme. But you need to have a decent understanding of JSON, HTML, Liquid, Shopify etc to DIY, and it's just time consuming and finicky to get right. These apps give you a really decent head start and give you really robust schema. 

If you just install one of those apps, you may actually get lucky and it could work, depends on your theme etc. But it's quite likely they will end up creating duplicate schema, not a major but still not an perfect fix. 

In saying all that, if you want to edit your own theme code, can you please find the existing schema code and paste it in here, then I can try add some suggestions. If you are unable to even find it, well frankly, I'd be concerned that you should be editing your own code at all... but start exploring around the product templates. 

Full time Shopify SEO guy, based in NZ. Sometimes freelance outside the 9-5.
0 Likes
Yvette5
New Member
2 0 0

Hi all!

 

Unfortunatly, I have the same problem.

My webshop is not indexed by Google because of the following problems.

How can I fix this?

 

- price valid until

- review

- aggregateRating

- Gtin/mpn/isbn

0 Likes
KieranR
Shopify Partner
257 22 77

Hey @Yvette5. So lack of schema or schema warnings won't prevent your site from being 'indexed'. 

If your store is new, it can take some time to begin to be indexed. I've noticed anywhere from a couple days to a couple months is normal on a site with a fresh domain (no authority) to start to show up in google results at all. 

But to fix those issues, you need to fix schema. Roughly the same answers as above. Edit theme or add an app that mostly does this for you.

Full time Shopify SEO guy, based in NZ. Sometimes freelance outside the 9-5.