184

I have this extract of website source code:

<meta content="This is a basic text" property="og:title" />

What does this property attribute stand for, and what is its purpose?

Chris Martin
  • 30,334
  • 10
  • 78
  • 137
luca
  • 36,606
  • 27
  • 86
  • 125

4 Answers4

143

og:title is one of the open graph meta tags. og:... properties define objects in a social graph. They are used for example by Facebook.

og:title stands for the title of your object as it should appear within the graph (see here for more http://ogp.me/ )

Marek Musielak
  • 26,832
  • 8
  • 72
  • 80
  • 7
    @luca — it tells you on the linked to page. – Quentin Jun 30 '11 at 13:46
  • 2
    Is it still necessary to use og, because if I want to improve my google page rankings, I remember reading that page related information should be within first 200-250 characters of the page. If I include og:title, og:description and some other fields how will my page ranking get affected? – Sahil Apr 27 '16 at 10:01
  • 1
    og meta tags shouldn't affect page ranking at all, those influence what will be displayed when you share a link to your page to someone (over fb, messenger, etc), usually a short card-like content will be displayed with a title, image and a short content next to the image – Mladen B. Jan 16 '20 at 14:20
19

The property in meta tags allows you to specify values to property fields which come from a property library. The property library (RDFa format) is specified in the head tag.

For example, to use that code you would have to have something like this in your <head tag. <head xmlns:og="http://example.org/"> and inside the http://example.org/ there would be a specification for title (og:title).

The tag from your example was almost definitely from the Open Graph Protocol, the purpose is to specify structured information about your website for the use of Facebook (and possibly other search engines).

Neddy
  • 503
  • 3
  • 15
  • 4
    I like the way you went into detail to explain the namespacing. Is it true, though, that the specification for title appears at the 'http://example.org/' address? I was under the impression that the value of the 'xmlns:og' merely had to uniquely identify the namespace, rather than point to it's actual specification. It's a fine point but I thought I'd mention it. I may be wrong. – JW. May 22 '14 at 16:43
4

A degree of control is possible over how information travels from a third-party website to Facebook when a page is shared (or liked, etc.). In order to make this possible, information is sent via Open Graph meta tags in the <head> part of the website’s code.

Mr Lister
  • 45,515
  • 15
  • 108
  • 150
ArunValaven
  • 1,753
  • 2
  • 25
  • 44
2

Probably part of Open Graph Protocol for Facebook.

Edit: guess not only Facebook - that's only one example of using it.

Shadow The GPT Wizard
  • 66,030
  • 26
  • 140
  • 208