One of the challenges of running a WordPress blog is to manage the comments effectively. Especially when your blog posts have lot of comments it will create difficulty for the users to reach out the comment box or view the footer area of your site. WordPress by default has a solution to handle large comments by pagination but you need to ensure not duplicating the content from search engines.
How to Activate Paginated Comments in WordPress?
Login to your WordPress admin dashboard and navigate to “Settings > Discussion”. Enable the checkbox for the last option “Break comments into pages…..” as shown below:
The option has three selections:
- Enter number of top level comments to be displayed on each page, say 20.
- Choose “last” page displayed by default.
- To ensure newer comments on top, choose “newer” comments at top of each page.
This will ensure the page only has 20 top level comments (nested comments are not considered) and the last page with latest comments will be displayed.
Adding Pagination
Save your changes once you have enabled the options and view the post which has more than 20 top level comments. You will see the pagination for the comments is enabled automatically under the comments section. The style of the pagination depends on the theme. Some themes may use numbers for pagination while others use previous / next for navigational links.
Content Duplication with Comments Pagination
Though breaking the comments is simple default settings this will create duplicate pages with same content. For example, if your original post’s URL is “yoursite.com/original-post/” then the paginated comment page will have an URL like “yoursite.com/original-post/comment-page-1/#comments”. Depending upon the number of comments there will be lot of comment pages with the same post content.
This will lead to duplicate content as search engines like Google will treat each page as a separate page.
How to Resolve Duplicate Content Issue with Pagination?
To handle situations with paginations you need to add a meta tag to each pages like below:
<meta link rel=“canonical” href=“yoursite.com/original-post/” />
It is easy to add this “rel=canonical” meta tag on few pages but it will be a difficult task to add the tag on all posts of your WordPress site. You need to have additional plugin in order to resolve this duplicate content problem at site level. This issue can be resolved by installing one of the two popular SEO plugins on WordPress repository – Yoast WordPress SEO or All in One SEO.
Yoast WordPress SEO
If you are using Yoast WordPress SEO plugin then you do not need to do anything. Yoast by default add “rel=”canonical”” meta tag on all posts / pages of your WordPress site. You can view the option on the plugin’s meta box available on WordPress visual editor. You need to click on the “Gear” icon to go to “Advanced” settings and the canonical URL option is the visible as the last option as shown below:
Leaving the text box blank by default points the canonical URL of the page / post to its permalink URL. In the above example, it will inform search engines the canonical URL as “yoursite.com/original-post/” which is what expected. If you prefer, you can add any other URL even cross-domain in the text box.
Once the post is published right click and view the source of the post. You can see the “rel=”canonical”” meta tag is added on all the paginated comment pages and pointing to the permalink URL of the post.
All in One SEO Plugin
Unlike Yoast SEO plugin, All in SEO plugin has an exclusive option to enable canonical URLs under “General Settings”. Ensure to activate this option and avoid duplicated content issue in search engines.
1 Comment
Leave your reply.