Bing Guide for Implementing Link Element Markup rel="next" and rel="prev" for Paginated and Sequenced Content

Implementing the rel="next" and rel="prev" link elements doesn't trigger a new visual treatment on web pages or on search result pages. It does, however, allow search eingnes to more comprehensively understand and index web content. In a April 16 blog post, David Flink, a Lead Program Managers at Bing detailed the steps to implementing this […]

Implementing the rel="next" and rel="prev" link elements doesn't trigger a new visual treatment on web pages or on search result pages. It does, however, allow search eingnes to more comprehensively understand and index web content.

In a April 16 blog post, David Flink, a Lead Program Managers at Bing detailed the steps to implementing this paganation solution.

"Traditionally, Bing has relied on a set of heuristics to determine if and how individual pages on a site are related to each other. Now, through the use of the optional rel="next" and rel="prev" link elements, you can provide Bing with a strong indication of the structure and scope of the sequenced content on your site," writes Forrester.

Here is an example of rel="next" and rel="prev" link elements for an oldest-to-newest sequence. In this example, webmaster has implemented the rel="next" and rel="prev" link elements, with the rel="next" link elements pointing to a newer article on the site. Forrester notes, that although it's perfectly acceptable to maintain multiple sequences on your site - for example, one sequence for news, one for politics, and one for finance - we encourage you to avoid adding more than one rel="next" and more than one rel="prev" link element to your pages."

bing: link elements for an oldest-to-newest sequence

Here is an example of link elements for a newest-to-oldest sequence for blogs. "The universally preferred order for blog posts is newest to oldest," notes Forrester. In the example below, the rel="next" link elements pointing to older blog posts on the site.

"As in the previous example, the first page in the sequence features just the rel="next" link element, while the last page in the sequence features just the rel="prev" link element. Avoid looping the sequence back to an index page on the last natural page of the sequence (using, for example, <link rel="next" href="index.aspx">), as this obscures the sequence," explains Forrester.

bing: link elements for newest-to-oldest sequence

Multi-Page Content

When implementing link element for multi-page, note, that user reading page 1 of a multi-page article will expect the next item in the sequence to be page 2, not a newer article. Here is an example of link elements for an oldest-to-newest sequence with multi-page content:

bing: link elements for an oldest-to-newest sequence with multi-page content

In other to implement the link elements, consider the pointers below:

  • Link elements should be added within the <head> section. "Alternative implementations, such as the addition of rel attributes to anchor elements in the body of your pages, are currently not supported," Forrester explains.
  • Using rel="next" and rel="prev" link elements, you establish a relationship between at most 3 pages on your site: the current page, the page immediately preceding the current page (rel="prev") and the page immediately following the current page (rel="next"). Note that the first page in the sequence should just contain the rel="next" link element, while the last page in the sequence should contain just the rel="prev" link element.
  • Avoid adding more than one rel="next" and more than one rel="prev" link element to your pages.

    "URL parameters, such as the ones includes in the example above, should be reflected in the HREF attributes of your link elements. URL parameters appended solely for tracking purposes, such as search queries and session identifiers, can also be appended. To avoid having these URL parameter surface in search results for your pages, you can use the rel="canonical" link element to specify a preferred URL for the content displayed," explains Forrester.

    For example, the page http://www.contoso.com/Products.aspx?Page=3&Query=Bikes may contain the following link elements:

    • Link elements should be added within the <head> section. "Alternative implementations, such as the addition of rel attributes to anchor elements in the body of your pages, are currently not supported," Forrester explains.
    • Using rel="next" and rel="prev" link elements, you establish a relationship between at most 3 pages on your site: the current page, the page immediately preceding the current page (rel="prev") and the page immediately following the current page (rel="next"). Note that the first page in the sequence should just contain the rel="next" link element, while the last page in the sequence should contain just the rel="prev" link element.
    • Avoid adding more than one rel="next" and more than one rel="prev" link element to your pages.

      "URL parameters, such as the ones includes in the example above, should be reflected in the HREF attributes of your link elements. URL parameters appended solely for tracking purposes, such as search queries and session identifiers, can also be appended. To avoid having these URL parameter surface in search results for your pages, you can use the rel="canonical" link element to specify a preferred URL for the content displayed," explains Forrester.

      For example, the page http://www.contoso.com/Products.aspx?Page=3&Query=Bikes may contain the following link elements:

      • A pointer to the preferred URL for the page content (without the URL parameter used for tracking): <link rel="canonical" href="http://www.contoso.com/products.aspx?page="3"">
      • A pointer to the next page: <link rel="next" href="http://www.contoso.com/Products.aspx?Page=4&Query=Bikes">
      • A pointer to the previous page: <link rel="prev" href="http://www.contoso.com/Products.aspx?Page=2&Query=Bikes">
    • You're free to exclude certain pages within the sequence (after applying the rel="next" and rel="prev" link elements) from indexing using the following meta element:
      • <meta name="robots" content="noindex, follow">