-
No: ‘noindex’ detected in ‘X-Robots-Tag’ http header
show on google search console
-
Hello,
We apologize for the issue you are facing with uploading your sitemap to Google Search Console. The error message indicating that a ‘noindex’ is detected in the ‘X-Robots-Tag’ HTTP header suggests that your sitemap or the pages listed in it may be set to noindex, which prevents Google from indexing them.
Here are some steps you can take to resolve this issue:
-
Check Your Sitemap: Ensure that your sitemap is correctly configured and accessible. You can validate your sitemap using tools like the Validate XML Sitemap.
-
Inspect HTTP Headers: Use a tool like httpstatus.io to check the HTTP headers of your sitemap URL. Look for the
X-Robots-Tag
header and ensure it does not contain a noindex directive.
-
Review Rank Math Settings: If your pages are set to noindex incorrectly, you can change this in Rank Math. Open the post/page in the WordPress Editor, find the Rank Math Metabox, and ensure that the Robots Meta is set to Index.
-
Exclude Sitemap from Caching: If caching plugins are used on your site, ensure that your sitemap is excluded from caching. You can refer to our tutorial on how to exclude sitemaps from caching.
-
Resubmit Your Sitemap: After making the necessary changes, remove your sitemap from Google Search Console and resubmit it as described in our tutorial on submitting a sitemap to Google.
If you continue to experience issues, please reply to this ticket with your site URL so we can assist you further. Thank you for raising this concern!
Sources:
How to Fix Submitted URL Marked ‘NoIndex’ Error » Rank Math
Troubleshooting the “Couldn’t Fetch” Error in Google Search Console » Rank MathHello,
Thank you for contacting Rank Math support, and sorry for the unexpected delays and any inconvenience that might have been caused due to that.
This is not an issue as XML Sitemaps are designed to be crawled by search engines, not indexed. The
X-Robots-Tag: noindex
directive ensures that the sitemap itself does not appear in search results, but this does not prevent Google from crawling its contents and indexing the pages listed within it.There’s no need to worry, as this is the expected behavior for sitemaps.
However, if you still wish to remove the noindex tag from your sitemap for any specific reason, you can use the filter in your site:
add_filter( 'rank_math/sitemap/http_headers', function( $headers ) { if ( '/sitemap_index.xml' !== $_SERVER['REQUEST_URI'] ) { return $headers; } unset( $headers['X-Robots-Tag'] ); return $headers; } );
Here’s how you can add filter/hook to your WordPress site:
https://rankmath.com/kb/wordpress-hooks-actions-filters/Don’t hesitate to get in touch with us if you have any other questions.
Hello,
Since we did not hear back from you for 15 days, we are assuming that you found the solution. We are closing this support ticket.
If you still need assistance or any other help, please feel free to open a new support ticket, and we will be more than happy to assist.
Thank you.
-
The ticket ‘Unable to upload sitemap on google search console’ is closed to new replies.