EN
FRENCH
繁体中文
RDFa (Resource Description Framework in Attributes) is a technology that adds machine-readable structured data to HTML and other markup documents using attributes.
It helps search engines and other applications understand the meaning and relationships of webpage content, rather than relying only on visible text.
RDFa is commonly associated with the Semantic Web, structured data, and linked data.
RDFa embeds structured information directly into HTML elements.
A typical process includes:
The result is machine-readable information expressed as RDF statements.
These attributes help applications interpret webpage content consistently.
RDFa and JSON-LD are both methods for representing structured data.
JSON-LD is often easier to maintain independently of page layout, while RDFa connects metadata directly to visible content.
Both RDFa and Microdata use HTML attributes to describe structured information.
itemscope, itemtype, and itemprop.Both approaches make webpage information easier for compatible software to interpret.
RDFa can help web scraping tools extract structured information from webpages.
Instead of relying entirely on CSS selectors or text patterns, a scraper may read RDFa attributes to identify products, organizations, or other entities.
However, RDFa is not present on every website, so scraping applications often need alternative extraction methods.
The following HTML describes a product using RDFa attributes:
<div vocab="https://schema.org/" typeof="Product">
<h2 property="name">Wireless Mouse</h2>
<p property="description">
Compact wireless mouse
</p>
</div>
In this example:
vocab identifies the vocabulary.typeof="Product" defines the entity type.property="name" identifies the product name.property="description" identifies its description.An RDFa-compatible parser can extract this information as structured data.
RDFa is a structured data technology that embeds machine-readable metadata directly into HTML using attributes.
It helps describe entities, properties, and relationships on webpages. RDFa is useful for Semantic Web applications and structured data extraction, although JSON-LD is another widely used approach.
Partnership