{
  "id": "microdata-html",
  "title": "Microdata (HTML)",
  "lang": "en",
  "source_lang": "en",
  "summary": "Microdata is an HTML mechanism for embedding machine-readable descriptions of entities and their properties within web pages.",
  "category": "computer-science",
  "subcategory": "software",
  "type": "concept",
  "aliases": [
    "HTML Microdata"
  ],
  "generated_at": "2026-10-14",
  "model": "gpt-6.1-sol",
  "url": "https://aiwiki.page/en/microdata-html/",
  "translations": {
    "zh-Hans": {
      "url": "https://aiwiki.page/zh/microdata-html/",
      "json": "https://aiwiki.page/zh/microdata-html.json"
    }
  },
  "sections": [
    {
      "heading": "",
      "text": "Microdata is a feature of HTML for embedding machine-readable information within web documents. It organizes annotations into items, each containing named properties whose values may be strings or other items. These annotations allow software to extract structured information alongside a page’s existing content. Microdata is specified in the HTML Living Standard. (html.spec.whatwg.org)"
    },
    {
      "heading": "Syntax and data model",
      "text": "Microdata uses five principal attributes:\n\nAttribute | Function\nitemscope | Creates an item; this is a Boolean attribute.\nitemtype | Identifies the item’s types using absolute URLs.\nitemprop | Assigns one or more property names to an element.\nitemid | Supplies a global identifier for an item.\nitemref | Identifies additional elements to inspect for properties, using their HTML id values.\n\nThe distinction between itemid and itemref is important: the former identifies an entity, whereas the latter connects markup within a document. (w3.org)\n\nUnder the Living Standard, multiple types on one item must use the same vocabulary. An itemid requires both itemscope and itemtype, and a vocabulary supporting global identifiers. Nesting an element with both itemprop and itemscope makes its item a property value of the enclosing item. (html.spec.whatwg.org)"
    },
    {
      "heading": "Vocabularies and example",
      "text": "Microdata supplies annotation syntax rather than a universal vocabulary. Schema.org supplies types and properties for describing entities such as people, organizations, products, events, and creative works. The distinction separates the mechanism for expressing data from the terms that give it meaning. (schema.org)\n\nThe following illustrative fragment describes a fictional person and an associated organization:\n\n<div itemscope itemtype=\"https://schema.org/Person\">\n  <span itemprop=\"name\">Alex Morgan</span>\n  <a itemprop=\"url\" href=\"https://example.org/alex\">\n    Profile\n  </a>\n  <div itemprop=\"worksFor\"\n       itemscope\n       itemtype=\"https://schema.org/Organization\">\n    <span itemprop=\"name\">Example Observatory</span>\n  </div>\n</div>\n\nHere, Person and Organization are vocabulary types; name, url, and worksFor are properties. The organization is a nested item, not merely the text inside its container. This pattern allows relationships between entities to be expressed through ordinary HTML elements. (schema.org)"
    },
    {
      "heading": "Property-value extraction",
      "text": "A property’s value depends on its element. Common cases include:\n\n- An element with itemscope: the nested item.\n- meta: its content attribute.\n- a, area, or link: its resolved href.\n- img and certain other media elements: their resolved src.\n- data or meter: its value attribute.\n- time: its datetime attribute when present.\n- Other elements: their text content.\n\nThus, a link’s displayed label is not its microdata URL value. (html.spec.whatwg.org)"
    },
    {
      "heading": "Applications and related formats",
      "text": "A major application is communicating page information to search engines. Structured descriptions can help a consumer identify such things as a recipe’s ingredients or a product’s offer details, rather than treating the page solely as unstructured text. Google Search supports Microdata, JSON-LD, and RDFa for structured-data features, subject to feature-specific requirements. Its documentation generally recommends JSON-LD for ease of implementation and maintenance, while accepting properly implemented Microdata. This is a consumer preference, not a change to Microdata’s status within HTML. (developers.google.com)\n\nMicrodata and RDFa attach annotations to document elements; JSON-LD commonly places a structured description in a separate script block. All can express Schema.org descriptions, so a vocabulary choice does not by itself determine the serialization format. (schema.org)"
    },
    {
      "heading": "Limitations and validation",
      "text": "Microdata has limited built-in facilities for expressing datatypes and language information compared with formats based on the Resource Description Framework. Interpretation of values therefore depends substantially on the vocabulary and consuming application. (w3.org)\n\nValidity also has several distinct levels: recognizable markup does not establish that its claims are accurate, that its vocabulary terms are appropriate, or that a particular service supports them. Google’s structured-data policies require descriptions to represent the page’s content and satisfy relevant feature guidelines. Correct markup does not guarantee enhanced search presentation. Its Rich Results Test evaluates eligibility for supported Google features rather than establishing the truth of the underlying information. (developers.google.com)"
    },
    {
      "heading": "Standardization history",
      "text": "Microdata developed during HTML5 standardization. W3C published a standalone Microdata Note on 29 October 2013, renewed work with a First Public Working Draft on 4 May 2017, and published another Working Draft on 26 April 2018. The standalone W3C specification was retired on 28 January 2021. This retirement concerns that publication track; Microdata remains specified in the WHATWG HTML Living Standard. (w3.org)"
    }
  ],
  "links": [
    "html",
    "search-engine",
    "json-ld",
    "rdfa"
  ],
  "sources": [
    {
      "title": "HTML Standard",
      "url": "https://html.spec.whatwg.org/multipage/microdata.html"
    },
    {
      "title": "HTML Microdata",
      "url": "https://www.w3.org/TR/2018/WD-microdata-20180426/"
    },
    {
      "title": "Getting Started - schema.org",
      "url": "https://schema.org/docs/gs.html"
    },
    {
      "title": "Intro to How Structured Data Markup Works",
      "url": "https://developers.google.com/search/docs/appearance/structured-data/intro-structured-data"
    },
    {
      "title": "General Structured Data Guidelines",
      "url": "https://developers.google.com/search/docs/appearance/structured-data/sd-policies"
    },
    {
      "title": "HTML Microdata publication history",
      "url": "https://www.w3.org/standards/history/microdata/"
    }
  ],
  "license": "https://creativecommons.org/licenses/by/4.0/"
}