Microdata (HTML) explained

Microdata is a WHATWG HTML specification used to nest metadata within existing content on web pages. Search engines, web crawlers, and browsers can extract and process Microdata from a web page and use it to provide a richer browsing experience for users. Search engines benefit greatly from direct access to Microdata because it allows them to understand the information on web pages and provide more relevant results to users.[1] [2] Microdata uses a supporting vocabulary to describe an item and name-value pairs to assign values to its properties. Microdata is an attempt to provide a simpler way of annotating HTML elements with machine-readable tags than the similar approaches of using RDFa and microformats.

In 2013, because the W3C HTML Working Group failed to find someone to serve as an editor for the Microdata HTML specification, its development was terminated with a 'Note'.[3] [4] However, since that time, two new editors were selected, and five newer versions of the working draft have been published,[5] [6] [7] [8] the most recent being Working Draft 26 April 2018.

Vocabularies

Microdata vocabularies do not provide the semantics, or meaning of an Item.[9] Web developers can design a custom vocabulary or use vocabularies available on the web. A collection of commonly used markup vocabularies are provided by Schema.org schemas which include: Person, "Place", Event, Organization, Product, Review, Review-aggregate, Breadcrumb, Offer, Offer-aggregate. The website schema.org was established by search engine operators like Google, Microsoft, Yahoo!, and Yandex, which use microdata markup to improve search results.[10]

For some purposes, an ad-hoc vocabulary is adequate. For others, a vocabulary will need to be designed. Where possible, authors are encouraged to re-use existing vocabularies, as this makes content re-use easier.

Localization

In some cases, search engines covering specific regions may provide locally-specific extensions of microdata. For example, Yandex, a major search engine in Russia, supports microformats such as hCard (company contact information), hRecipe (food recipe), hReview (market reviews) and hProduct (product data) and provides its own format for definition of the terms and encyclopedic articles. This extension was made in order to solve transliteration problems between the Cyrillic and Latin alphabets. After the implementation of additional parameters from Schema's vocabulary, indexation of information in Russian-language web-pages became more successful.

Global attributes

Example

The following HTML5 markup may be found on a typical “About” page containing information about a person:

Hello, my name is John Doe, I am a graduate research assistant atthe University of Dreams.My friends call me Johnny. You can visit my homepage at www.example.com/~JohnnyD.I live at 1234 Peach Drive, Warner Robins, Georgia.

Here is the same markup with added Schema.org[11] [12] [13] Microdata:

Hello, my name is

John Doe, I am a graduate research assistant at the University of Dreams. My friends call me Johnny. You can visit my homepage at .

I live at

1234 Peach Drive, Warner Robins, Georgia.

As the above example shows, Microdata items can be nested. In this case, an item of type http://schema.org/PostalAddress is nested inside an item of type http://schema.org/Person.

The following text shows how Google parses the Microdata from the above example code. Developers can test pages containing Microdata using Google's Rich Snippet Testing Tool.

Item Type: http://schema.org/Person name = John Doe jobTitle = graduate research assistant affiliation = University of Dreams additionalName = Johnny url = http://www.example.com/~JohnnyD address = Item(1) Item 1 Type: http://schema.org/PostalAddress streetAddress = 1234 Peach Drive addressLocality = Warner Robins addressRegion = Georgia

The same machine-readable terms can be used not only in HTML Microdata, but also in other annotations such as RDFa or JSON-LD in the markup, or in an external RDF file in a serialization such as RDF/XML, Notation3, or Turtle.

Support

See also

Notes and References

  1. Web site: MicroData - The Future of Search Engine Relevance and Optimization (SEO) . Lyquix.com . 2016-06-30.
  2. Schema.org http://schema.org/
  3. WG Decision to publish HTML Microdata as a WG Note . public-html-admin@w3.org . 2 Oct 2013 . Paul . Cotton . 2016-06-30.
  4. Web site: HTML Microdata . W3.org . 23 June 2014 . 2016-06-30.
  5. Web site: HTML Microdata W3C First Public Working Draft 04 May 2017. World Wide Web Consortium (W3C). 2017-09-06.
  6. Web site: HTML Microdata W3C Working Draft 26 June 2017. World Wide Web Consortium (W3C). 2017-09-06.
  7. Web site: HTML Microdata W3C Working Draft 09 October 2017. 9 October 2017. World Wide Web Consortium (W3C). 16 March 2018.
  8. Web site: HTML Microdata W3C Working Draft 10 October 2017. 10 October 2017. World Wide Web Consortium (W3C). 16 March 2018.
  9. Web site: HTML Standard . Web Hypertext Application Technology Working Group . 30 December 2016.
  10. Book: MacDonald, Matthew. HTML5: The missing manual. 2nd. O'Reilly and Associates. 2014. 978-1-4493-6326-0.
  11. Web site: Documentation . Schema.org . 2016-06-30.
  12. Web site: Type Hierarchy . Schema.org . 2016-06-30.
  13. Web site: Schema.org Turtle RDFS Schema . 2013-05-29 . https://web.archive.org/web/20140921103224/http://schema.rdfs.org/all.ttl . 2014-09-21 . dead .
  14. Types of Rich Snippets . https://ghostarchive.org/varchive/youtube/20211215/4W8Ah394bH8 . 2021-12-15 . live. Google Webmasters Channel . Video . 2011-12-06 . 2016-06-30.
  15. Web site: Microdata DOM API - Web APIs MDN. 2021-07-05. developer.mozilla.org. en-US.
  16. Web site: Opera Software Documentation Team . Opera 11.60 for Windows changelog . Opera.com . 2011-12-06 . 2016-06-30 . https://web.archive.org/web/20141023082043/http://www.opera.com/docs/changelogs/windows/1160/ . 2014-10-23 . dead .
  17. Web site: 909633 - Remove HTML Microdata API. 2021-07-05. bugzilla.mozilla.org. en.