Implementing Schema.org Microdata

Last week, Google, Bing and Yahoo announced collaboration on a single standard for structured markup. Yes, I’m talking about Schema.org and utilizing Microdata for “Rich Snippets.”

Since then, many sites have posted about why Schema.org might be good, bad or otherwise for site owners; some balanced, some not. Personally, I think structured markup and machine-readable information is always good to have on your site, regardless of potential SEO benefits. I’ve had a love for structured markup (in the form of Microformats) since I first laid eyes on hCard several years ago. I could have written a whole post about why I think Schema.org is good for SEO, but instead I decided to implement it on a site of mine.

I co-own a book review site, and I’ve been meaning to implement the microformat hReview on it for over a year. I never got around to it because it involved creating custom post types in WordPress, and I knew that would be a time-consuming affair. I finally bit the bullet and sat down to do that on Sunday. That part took about 5 hours of my day.

Then, I started implementing microdata. From never having implemented microdata before in my life (like I said, I was a Microformats fan), I found out what markup I needed, added it to my template, and tested it in about an hour.

I started out by making a list of all of the attributes about books that we use in a review. Then I determined which item type (itemtype) it would be associated with – for my purposes, Book, Review , and Rating were all I needed. Then, I noted which item property (itemprop) I would use. Then it was simply a matter of adding the appropriate markup to my existing HTML and PHP.

There were a couple of attributes that were confusing – for example, do I use description or reviewBody from Review? Do I use aggregateRating from Review, or reviewRating from Rating? The examples on Schema.org were helpful to a degree, but I still felt like I was guessing at proper use. Time will tell if I’ve used the appropriate item properties. I also wasn’t sure if I had to upgrade the doctype to HTML5 or not, but I chose not to as only modern browsers support it and some of my users have older browsers.

To test that you’ve implemented microdata correctly, you can use Google’s Rich Snippet testing tool. However, it was throwing errors for things it should not have had a problem with (I suspect it was getting a lot of use over the last week as people rushed to add microdata to their sites), so I looked for an alternative. I found this Microdata Tool using jQuery to test that I had applied the code correctly; unfortunately it can’t show how Google might display this data in the SERPs.

One of the arguments the naysayers against Schema.org are using is that it will take too long/too many resources to implement, but clearly that is not the case. I’m going to continue to tinker with microdata and my review template, and monitor my organic search rankings and conversion rates to determine just what the effect of adding it will be over time.

About Dawn Smith

Dawn Wentzell is currently working in custom mobile app development as Project Manager, Mobile Technology at SpeakFeel Corporation. She has experience with SEO for both local businesses and national markets, loves to do site audits and hates IIS hosting. You can find her at dawnwentzell.com or on twitter at @saffyre9.

Comments

  1. Dawn, nice breakdown of using Schema.org. We’ve worked with a couple clients now on successful hReview implementations, so my concern is what advice I give them. We know they’re starting to see hReview appear in rich snippets (took time, but within a month they popped). Do we abandon microformats for microdata now? Should we do this for the clients that are already benefiting from the current microformat structure? Did some digging and I’m going to stick with microformats for now. We’ll test the microdata setup for reviews and ratings to see if those get indexed as quickly and if so, moving forward will recommend them, but personal opinion is that it isn’t worth changing at this point. Schema.org even mentions possibly supporting microformats if usage picks up, but I won’t hold my breath, “We will also be monitoring the web for RDFa and microformats adoption and if they pick up, we will look into supporting these syntaxes.”

    • Yeah, it’s tough if you’ve just implemented something else when clients hear about this. What I’m loving about microdata so far, though, is that I can define it as a Book in addition to being a Review. I’m kind of excited to see how that shows up in the SERPs.

  2. Yeah, that does seem really exciting. :) Weee, fun new toys! Did you catch that Google Webmaster Tools will now integrate with Analytics? More nerdy things to love this week…

  3. Nice to hear that adding the item* attributes wasn’t too much of a hassle. About the doctype, note that browsers don’t really support doctypes in the way one may imagine, they’re merely triggers for Quirks Mode, Standards Mode and Almost Standards Mode, which you can read about in http://hsivonen.iki.fi/doctype/#handling

    The moral of the story is that it’s quite safe to use the HTML5 doctype. There may be other reasons for preferring something else, but browser compatibility isn’t an issue.

    • Oh, now that’s handy! Thanks Philip. *bookmarked*

      I was mostly concerned about triggering quirks mode in IE6, to be honest. I can accept “Almost Standards” though, so I might go ahead and do that.

  4. I’m trying to implement schema microdata on my review site as well and was wondering if I could view the source for how you did it. I find the examples on the official webpage to be less than satisfactory. Is the whole thing of itemtype Review or is it Book? Where do you make that differentiation?

  5. Google’s Rich Snippets Testing Tool still does not properly support schema.org markup, doh! I believe I got everything looking good and I see reviews are showing up well in the tool but no stars on the search result representation. Ah well. Hopefully it works in the real search results and hopefully I will see.

  6. brrip 720p says:

    when i preview my blog it shows “This page does not contain authorship or rich snippet markup”. Can you tell how to solve this???????

  7. blogger to wordpress says:

    Great article :)

    I started to use it to format page for FastFoodRestaurant … but I’m not quite sure how to use itemprop “menu” that belongs to FoodEstablishment :(

    I have picture of food items from menu, short description, calories and price.

    Do you maybe have any suggestions ?

    • So Schema is really concerned with people, places and things…I suppose you could argue that menu items from a restaurant count as a Product, but the data type for FastFoodRestaurant doesn’t indicate that’s necessary. It’s really more about the location of the restaurant than anything else.

      I think you’d be more than fine just using itemprop=”menu” on the link to the menu page, and perhaps even wrapping the contents of the menu page in

  8. blogger to wordpress says:

    Thanks for advise…what I did is that I wrapped menu and then used itemprop=”menu”

    but I’m still not quite sure is it ok…the other option was to add itemprop=”menu” to every item…but this first make more sence

  9. Hi I have two websites which I would like to use schema microdata on. One is a Site dealing with my family the other is a site dealing with my home town how would I use schema on these as I would like to explain what each site is about

  10. Olav Cleemann says:

    “Semantic inspector” extension for Google Chrome works well.