1

I am adding Schema.org Microdata to one of the website homepage. This website has a logo which is surrounded with <a> anchor tag. This anchor tag already uses itemprop="url" like this:

<a href="https://mywebsite.com" itemprop="url" title="'My Website'" rel="home" id="logo"><img src="/logo.png" alt="My Website" itemprop="logo" /></a>

Should I add <meta> tag with itemprop="url" or having <a> with itemprop="url" is enough?

Which one is correct?

One:

<header id="header" role="banner">
  <div itemprop="publisher" itemscope itemtype="http://schema.org/Organization">
    <a href="https://mywebsite.com" itemprop="url" title="'My Website'" rel="home" id="logo"><img src="/logo.png" alt="My Website" itemprop="logo" /></a>
    <meta itemprop="name" content="My Website" />
    <meta itemprop="telephone" content="+61 123 123 123" />
    <div itemprop="address" itemscope itemtype="http://schema.org/PostalAddress">
      <meta itemprop="streetAddress" content="Level 1" />
      <meta itemprop="addressLocality" content="SomeCity" />
      <meta itemprop="addressCountry" content="AU" />
      <meta itemprop="postalCode" content="4000" />
    </div>
  </div>
</header>

Two:

<header id="header" role="banner">
  <div itemprop="publisher" itemscope itemtype="http://schema.org/Organization">
    <a href="https://mywebsite.com" itemprop="url" title="'My Website'" rel="home" id="logo"><img src="/logo.png" alt="My Website" itemprop="logo" /></a>
    <meta itemprop="url" content="https://mywebsite.com">
    <meta itemprop="name" content="My Website" />
    <meta itemprop="telephone" content="+61 123 123 123" />
    <div itemprop="address" itemscope itemtype="http://schema.org/PostalAddress">
      <meta itemprop="streetAddress" content="Level 1" />
      <meta itemprop="addressLocality" content="SomeCity" />
      <meta itemprop="addressCountry" content="AU" />
      <meta itemprop="postalCode" content="4000" />
    </div>
  </div>
</header>

Format Two has extra <meta itemprop="url" content="https://mywebsite.com">.

  • What gave you the idea to use meta in addition? – unor Nov 3 '17 at 17:17
  • @unor I was wondering if having <meta itemprop="url" content="https://mywebsite.com"> is correct way or having itemprop="url" on anchor tag is correct way. – MutantMahesh Nov 9 '17 at 1:03
1
  • I think that both of your options will work. The practice of applying meta: for machine-readable content and symbols that may be incomprehensible to users. For example, you have designated country for your organization follows the meta: <meta itemprop="addressCountry" content="AU" />. A user who is little familiar with geographic reductions may not understand what country is named as an AU. But the machines understand this is Australia.
  • At the same time, I want to note that the markup you specify may have a risk of getting a penalty from Google. If meta-structured data (not visible to users) is not duplicated by visible information, Google can take it as spam in structured data - marking up content that is invisible to users - read more Search Console Help - Manual Actions report:

Spammy structured markup. If you see this message on the Manual Actions page, it means that Google has detected that some of the markup on your pages may be using techniques that are outside our Rich snippets guidelines, for example: marking up content that is invisible to users, marking up irrelevant or misleading content, or other manipulative behavior.

Therefore, I recommend that you duplicate meta-information in the content as visible to users.

1

It’s always preferable to use your existing markup for Microdata. Only use meta/link elements for values that can’t/shouldn’t be displayed on the page.

Note: If the value is a URL, it’s not allowed to use the meta element. You have to use the link element instead.

So if you have an a element with the correct/canonical URL in href, specify the Microdata directly on this a element:

<a itemprop="url" href="https://example.com/">…</a>

If you don’t have such an a element (or if it doesn’t contain the canonical URL in href), add a link element:

<a href="https://example.com/?ref=foo">…</a>
<link itemprop="url" href="https://example.com/" />

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.