Yasr Structured data

Have you ever noticed the stars in google search results? I’m sure you did!
And if you are here it’s because you want them too! With YASR you can easily add rich snippets in your posts/pages.

In the single post or page, you can choose if it’s a review or not (see image).

What does this mean?

Review Rating

If you select “Yes” to “is this a review?“, your site will be indexed in search engines like the image to the right: as you can see, it is simply the rating given by the author, so it gets data from yasr_overall_rating shortcode.

Aggregate Rating

If you select, instead, “No“, your site will be indexed in search engines using your readers’ rating; data will be taken from yasr_visitor_shortcode

Users’ Review

With YASR Pro, if enabled, all the rating data will be taken from the users’ reviews, so pages will be indexed like the image on the right.

Leave a Reply

Your email address will not be published. Required fields are marked *

21 thoughts on “Yasr rich snippets

  1. Hi Dario,
    so far your plugin is wonderful and perfect for my blog! Thank you first at all.
    I struggle with one detail in the recipe rich snippet. The time should be inserted with ISO 8601 format, I tired it so many times and just do not know what format to use. P1H?

    Can you maybe support? So like for a recipe I need a time duration like 45 mins, or 1 hour 20 mins.

    Thank you and regards from Germany.

    1. Hi Madeline!

      From Wikipedia:

      The capital letters P, Y, M, W, D, T, H, M, and S are designators for each of the date and time elements and are not replaced.

      P is the duration designator (for period) placed at the start of the duration representation.
      Y is the year designator that follows the value for the number of years.
      M is the month designator that follows the value for the number of months.
      W is the week designator that follows the value for the number of weeks.
      D is the day designator that follows the value for the number of days.
      T is the time designator that precedes the time components of the representation.
      H is the hour designator that follows the value for the number of hours.
      M is the minute designator that follows the value for the number of minutes.
      S is the second designator that follows the value for the number of seconds.

      For example, “P3Y6M4DT12H30M5S” represents a duration of “three years, six months, four days, twelve hours, thirty minutes, and five seconds

      So, if you need 1h and 20 min, use PT1H20M, or, to use 45min, just put PT45M

      Hope this helps.

      1. Thank you so much Dario.
        I missed the T. Sure it will work now.

        Thank you for your support and help.
        Have a nice day, Madeline

  2. Hi, if I use shortcode [yasr_overall_rating] there is no json microdata. Is it possible to add something to shortcode or in php to define proporties of object manually?

    1. Hello Adam, sorry for the delay of this answer.

      If you want to use microdata for [yasr_overall_rating] shortcode, you’ve to select “Review Rating” at this question in the setting:

      Which rich snippet do you want to use?


  3. Hi, wonderful plugin!

    Is posible to deactivate rich snippets? I’m trying to apply ratings to pages that are neither products, places, recipes, blogs. Instead, they are something more similar to companies, or groups. I was thinking that maybe have a rich snippets that is not correct can be harmful for SEO.


    1. Hello, sorry for the delay of this answer!

      It’s not possible with a setting, we’ve to insert a little function in your child theme!

      Is it ok for you?

      1. Thank you for your answer!

        We have a customised theme, so no child. So i think that I just should insert the function in the function.php file?

          1. Yes, true but the theme (not programmed by me) is a custom teme, so don’t know who will update it and when. Anyway, if I have to apply only some functions without a child theme, I use Code Snippets..

      1. I need to Review Count with YASR ( on the picture).
        But I just bought( Yasr Custom Rankings) that can’t do it( picture).
        So I can hope to have -Ratng:7.8/-2,659 reviews.
        I have purchased plugin.
        Do this? If Unable.
          Can replace ?
        I am not good at Engilish.
        Zeng pppdog

        1. Hi, I just bought your plugin “Yasr Custom Rankings”. However, due to my poor English (I’m not a native speaker), I’m sorry I made a stupid mistake. Actually, what I wanted was “Review Count with YASR”. Is it possible to allow me apply for a change?

          1. Thanks for your reply. But when I logged in My Purchase and go to “View Details and Downloads”, I didn’t see any download link of “Yasr User Review” or “Review Count with YASR”, what I only see is still the download link of “yasr-custom-rankings-0.0.8” only. Please check it again for me.