I am not able to get my structured data to return an error free response from Google's Structured Data Testing Tool. This is the code I am putting in:

<script type="application/ld+json">
    "@context": "https://schema.org/", 
    "@type": "Product", 
    "additionalType": "http://www.productontology.org/id/Scooby_doo",
    "sku": "<?php echo $productID; ?>",
    "identifier_exists": "no",
    "gtin": "",
    "mpn": "",
    "name": "<?php echo $heading; ?>",
    "url": "https://www.blah.co.uk/services/#<?php echo $sector_id; ?>",
    "image": "<?php if($background_image != '') :?><?php echo $background_image; ?><?php else : ?><?php echo $background_video_poster; ?><?php endif;?>",
    "description": "<?php echo $text; ?>",
    "brand": "Scooby Doo",
    "aggregateRating": {
        "@type": "AggregateRating",
        "ratingValue": "5",
        "bestRating": "5",
        "worstRating": "5",
        "ratingCount": "10"

I then receive these errors:

identifier_exists ~ no (The property identifier_exists is not recognized by Google for an object of type Product.)

offers ~ The offers field is recommended. Please provide a value if available.

review ~ The review field is recommended. Please provide a value if available.

warning ~ This Product is missing a global identifier (e.g. isbn, mpn or gtin8). Please see documentation for valid identifiers.

My confusion - I take the global_identifier out of the code, then it requests it be added in, within the new error list created when I run it without. I have also tried just using an mpn or gtin without the global identifier, still no positive result.

Please can someone help me figure out the values that are plugged in to provide 'no / null' global identifier or mpn / gtin?

Thanks, Jason.

1 Answer 1


I would say, your code is pretty ok. Lets look at errors the test tool fires:

  • identifier_exists: you don't need to use it, Google doesn't know it
  • Warnings about missed offer and review: are not critical, but better to use.

SKU may be the same as GTIN and as MPN. Those are just product identifiers. It is fully enough to have a single one of them.

I've edited your code and checked it with testing tool - looks not bad: enter image description here

  • Appreciate you taking a look, can I just re-iterate the question with you. How do I present a 'no / null' value? Jan 15, 2020 at 16:35
  • 1
    You don't need to present an absence of value. No value means no property.
    – Evgeniy
    Jan 15, 2020 at 17:53
  • 1
    If you use the newer Rich Results testing tool you will see that it uses the word "optional". These are just warnings for properties that Google does look for, but does not require. The documentation uses the word "recommended". If you don't have a value for them, don't worry about the warning. Jan 16, 2020 at 0:04
  • Okay thanks for taking the time guys. Jan 16, 2020 at 9:07

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.