Not a bug Incorrect og:url and lack of sitemap inclusion of canonical url for secondary thread pages - affecting SEO

bzcomputers

Well-known member
Affected version
2.2
Currently on secondary thread pages the "og:url" and "canonical" url look like:

HTML:
<meta property="og:url" content="https://xenforo.com/community/threads/xenforo-2-2-release.171961/" />
<link rel="canonical" href="https://xenforo.com/community/threads/xenforo-2-2-release.171961/page-2" />

1) Open Graph & Facebook say this "og:url" would be incorrect. The both specifically say the "og:url" should be equal to the "canonical" url. You can see this described in both the Open Graph protocol and Facebook's interpretation of it.


I have looked at some other forum software options out there and a couple do the same as XenForo currently - using the first thread page url as the "og:url" for all secondary thread pages, but I would have to say they would be incorrect also.


2) The canonical url for secondary thread pages is correct because the content is unique and not a duplicate of the first thread page. The issue is that Google says "all canonical urls should be specified in the sitemap", which currently is not occurring in XenForo 2.1 or 2.2. By default secondary thread pages should be included in the sitemap according to Google.

 
These two issues are really distinct but since you've reported them together, I'll respond to both.

Regarding your og:url comments, we generally disagree with your interpretation of the docs. Notably, the meaning of og:url and rel=canonical are different and thus do not have to agree. The og:url represents the canonical URL of an object for the purposes of the open graph. We consider the thread in its entirety to be the object, so sharing the canonical version of the thread (which is its first page) is the correct/intended behavior. The Facebook docs you've linked to even give examples of the og:url not being the same as the rendered URL.

In terms of including subsequent thread pages in the sitemap, there is an open suggestion for that (as this has been the behavior since the sitemap was introduced). There's also an add-on that does this, though anecdotes from the discussion don't really demonstate increased search results visibility (though more pages are indexed). So we'd generally refer this back to the suggestion.
 
Top Bottom