Skip to main content
HTML Validation

The “itemtype” attribute must not be specified on elements that do not have an “itemscope” attribute specified.

About This HTML Issue

When the itemtype attribute is specified on an HTML element, the boolean attribute itemscope must also be present in that element.

Here’s an example of how to use the itemscope attribute with the itemtype attribute:

<div itemscope itemtype="http://schema.org/Person">
  <p><span itemprop="name">Liza Jane</span></p>
  <p><span itemprop="email">liza.jane@example.com</span></p>
</div>

In this example, the itemscope attribute is used to indicate that the div element is a microdata item, and the itemtype attribute is used to specify that the type of this item is http://schema.org/Person.

If you don’t need to specify a type for the data represented by the HTML element, you can simply remove the itemtype attribute. For example:

<div itemscope>
  <p><span itemprop="name">John Doe</span></p>
  <p><span itemprop="email">john.doe@example.com</span></p>
</div>

Find issues like this automatically

Rocket Validator scans thousands of pages in seconds, detecting HTML issues across your entire site.

Help us improve our guides

Was this guide helpful?

Ready to validate your sites?
Start your free trial today.