Errors & missing attr. in LDJSON

  • Hi,
    When I test the LDJSON of my products in Google Data Structure Tool, I get to many errors and warning in isRelatedTo and in isSimilarTo.
    Seems that is missing to many attibutes (sku, image, descriotion, …)
    You can check youself here

    Also, I use the plugin Product GTIN to set the GTIN code in my products, but I can’t see the GTIN attributes on my Rich Snippets LDJSON.

    Best regards

Viewing 6 replies - 1 through 6 (of 6 total)
  • Hello,

    Thank you for contacting Rank Math and sorry for any inconvenience that might have been caused due to that.

    Would you mind sharing a link to one of the affected pages so that we can perform some tests?

    Looking forward to helping you. Thank you.



    Thank you for contacting Rank Math today.

    It looks like you have not configured all these options for most of your products. For instance on the first link that you have shared, the mpn value has been set for the main product on the page but the rest of the related product lack these attributes.

    The aggregateRating and review fields are taken from your actual product reviews that your buyers/customers leave on your products.

    If you don’t have any reviews yet, that is going to show up as a warning in the schema testing tool. That’s because Google will actually look for those fields.

    Please acquire some reviews and ratings to get rid of the aggregateRating and review warnings.

    You can fix the SKU and availability issue easily as well:

    To fix the brand warning, head over to WordPress Dashboard > Rank Math > General Settings > WooCommerce and choose from any of the available fields to use as your product’s brands.

    Brand Value

    If you want to use a custom value for your Brands, you can do that by using the following code in your theme’s functions.php file:

    // Add Brand for Products.
    add_filter( 'rank_math/snippet/rich_snippet_product_entity', function( $entity ) {
    $entity['brand'] = 'Rank Math;
    return $entity;

    Replace the “Rank Math” text with your actual brand name then run your website through the Structured Data Testing tool once again.

    Hope that helps and please do not hesitate to let us know if you need our assistance with anything else.

    I setup all this featues
    The problem is not in parent product but in isRelatedTo and in isSimilarTo products.

    The plugin do add the json attributes to isRelatedTo and in isSimilarTo.

    You can saw the output here

    Hi Amdre,

    Thanks for getting back to me.

    I am consulting our dev team about this and we will be in touch in a short while.

    We appreciate your patience. Thank you.


    Google Structured data testing tool throws warning for the missing fields in the isrelatedTo attribute but it’s a false positive. In isRelatedTo field only product name and URL of the related products are required. You can check this in the new Google Rich Snippet testing tool:

    Still, if you want to remove the isRelatedTo then please add the following code in your theme’s functions.php file:

    add_filter( 'rank_math/snippet/rich_snippet_product_entity', function( $entity ) {
    	if ( isset( $entity['isRelatedTo'] ) ) {
    		unset( $entity['isRelatedTo'] );
    	return $entity;

    Hope that helps. If there is anything else, please let us know.

    Thank you.


    Since we did not hear back from you for 15 days, we are assuming that you found the solution. We are closing this support ticket.

    If you still need assistance or any other help, please feel free to open a new support ticket, and we will be more than happy to assist.

    Thank you.

Viewing 6 replies - 1 through 6 (of 6 total)

The ticket ‘Errors & missing attr. in LDJSON’ is closed to new replies.