• Resolved moneysaurus

    (@moneysaurus)


    Greetings,

    I need help in noindexing category archive pages except the first one for each category.

    While I have indexed the category pages in Search Appearahce>Taxonomies>Categories, I don’t see how I can noindex all the subsequent category pages that will come after the first one as soon as I add more posts to the category page 1 and run out of space on the page 1 (at least in the desktop version of my MagazinePro theme which has limited number of post per category page)

    So far, I have published only 2 posts per category page. Still, as I add more posts to category, I will run out of space on page 1 and just wanted to know my options for noindexing next category pages. Please help. Thank you!

    -Eugene

    The page I need help with: [log in to see the link]

Viewing 4 replies - 1 through 4 (of 4 total)
  • Hi,

    Yoast does not have a feature which would add a noindex tag to those archive pages. Google will eventually add a noFollow tag to those pages which is bad for SEO. So we let those pages get indexed. This guide explains more: https://yoast.com/yoast-seo-6-3/.

    However, if you wanted to go ahead and add a noindex tag you can use the code snippet below. It would go into your functions.php of your theme. If you are not sure where that is or how to add the code your theme developer can help. We also recommend taking a backup. Your host provider can help with this.

    Lastly, depending on your set-up the code snippet might require some modification.

    Unfortunately, there’s a difference between the support we can offer and the level of programming needed to change (core) features of our plugin. Since we don’t want to take the risk that we break your website by suggesting incorrect or incomplete code, we cannot advise you on how to make such changes. And even though we cannot be of any assistance, you’re completely free to change anything in the plugin to better suit your needs.

    We highly recommend checking out?our list of Yoast Partners here https://yoast.com/yoast-partners/ in case you are in need of development.

    We will also keep this issue open for 2 weeks in case someone from the community can help. Perhaps a developer watching these forums can assist further. After which, we will close in order to keep the overview.

    Code to add:

    add_filter( 'wpseo_robots', function( $robotsstr ) {
    if ( is_front_page() && is_paged() ) {
    return 'noindex, follow';
    }
    
    return $robotsstr;
    } );
    Thread Starter moneysaurus

    (@moneysaurus)

    Hi Pcosta88,

    Thank you so much for that! I have read through the link and the reasoning behind Yoast removing indexing for category subpages makes perfect sense for me. I think I will live with that and will not make any changes.

    Still, I am also thankful for the piece of code to make the changes and noindexing the subpages if I decide to do it sooner or later.

    Thank you again!

    Best,
    Eugene

    Plugin Support Jerlyn

    (@jerparx)

    Hi @moneysaurus ,

    You’re welcome! Should you have further concerns, just let us know. This post is open for the next 2 weeks as mentioned.

    Plugin Support devnihil

    (@devnihil)

    We are going ahead and marking this issue as resolved due to inactivity. If you require any further assistance please create a new issue.

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘Nonindex category archive pages from 2d’ is closed to new replies.