<data>...</data>

HTML4 HTML5

Links human-readable content with a machine-readable value defined in the value attribute (useful for scripts or search engines).

Both opening and closing tags are required.

Attributes:

value="..." - (Required) Machine-readable value associated with content (e.g., product code, unique ID, quantity in standard unit).

Example

Code:

<ul style="list-style-type: none; padding-left: 0;"> <li>Product: <data value="PROD-9981">Whole bean coffee 500g</data></li> <li>Price: <data value="49.99">$49.99</data></li> </ul>

The browser will interpret this code as follows:

  • Product: Whole bean coffee 500g
  • Price: $49.99