Block Second Page Of Your WordPress Post From Search Engine

Google and other search engines are now strict for duplicate content to show quality pages to visitors plus there are lot of penalties and search engine updates related to them and it reduce your visitors. Or you might see lot of duplicate description on your webmaster tool of your website or may be second page of your article or post is ranking instead of original page then you need to block second and greater pages from search engine.

Duplicate Content WordPress

To block second or greater page of  WordPress post, category or any archive then you need to use the following code:

<?php if ( is_paged() )  { ?>
<meta name="robots" content="noindex, follow" />
<?php } ?>

And if you want to rank or index first page of your WordPress website then you could use this code:

<?php if ( !is_paged() )  { ?>
<meta name="robots" content="index, follow" />
<?php } ?>

These code will help search engine bot to understand the original page plus will help to rank more better your post or original article. It will reduce the duplicate pages and will protect you from any search engine penalties. You could also block duplicate pages from All In One SEO or Yoast SEO plugin if you using them.

Leave a Reply

Your email address will not be published. Required fields are marked *