• Resolved Rafael Nunes

    (@rafaelnunes)


    Hi, how do I remove noindex from the homepage?

    <meta name=robots content=’noindex, follow’/>

    I’ve already tried the settings like in the Settings > Reading menu, I’ve also forced search engine permission within the Yoast Seo settings within the home page, but nothing removes. I’ve also tried a code in function.php and also not removed, just add the string at the end, so it looks like this: noindex, follow, index, follow. Here’s the code:

    /**
    * EDITED BY OBOT ERNEST
    * REMOVES NOINDEX META TAG FROM HOME PAGE & SEARCH PAGE IMPLEMENTED BY YOAST
    */

    add_filter(‘wpseo_robots’, ‘yoast_no_home_noindex’, 999);
    function yoast_no_home_noindex($string= “”) {
    if (is_home() || is_front_page() || is_search()) {
    $string= “index,follow”;
    }
    return $string;
    }

    I don’t know what to do, google doesn’t just index the home page because of the presence of this noindex on the site. Does anyone have a solution?

    • This topic was modified 3 years, 8 months ago by Rafael Nunes.

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

Viewing 3 replies - 1 through 3 (of 3 total)
  • Plugin Support devnihil

    (@devnihil)

    @rafaelnunes We’re sorry to hear you are experiencing this issue on your site.

    There are a number of ways you can set pages to noindex, so we would recommend checking all of them.

    We would first recommend checking to make sure the robots meta tag is NOT set to noindex for the content type or taxonomy as a default setting, and you can check this setting by performing the following actions:

      ? In WordPress go to SEO>Search Appearance>Content Types
      ? For Pages set ‘Show Pages in search results’ to ‘Yes’
      ? Click ‘Save Changes’

    In addition, you can set pages/posts setting of whether to be indexed individually on the page’s edit screen. You can check this by performing the following actions:

      ? Go to the Edit screen for a page/post
      ? Scroll down to the Yoast metabox
      ? Click on the ‘Advanced’ area
      ? For ‘Allow search engines to show this Page in search results?’ make sure this is set to ‘Yes’
      * Note (setting this value to Yes will set meta robots to index and setting No would set meta robots to noindex)

    Also, you are able to control the global indexing of the site in WordPress. You can check this in the following way:

      ? In WordPress go to Settings>Reading
      ? Make sure for ‘Search Engine Visibility’ that ‘Discourage search engines from indexing this site’ is NOT checked
      ? Click ‘Save Changes’

    We also have a guide on how to set a page/post’s meta robots tag to noindex here: https://yoast.com/help/how-do-i-noindex-urls/

    Thread Starter Rafael Nunes

    (@rafaelnunes)

    I’ve done all these processes, but it still has the same problem.

    Thread Starter Rafael Nunes

    (@rafaelnunes)

    I managed to solve the problem, woocommerce was blocking page indexing.

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘How to remove noindex from homepage’ is closed to new replies.