Title: Sitemaps error?
Last modified: July 18, 2022

---

# Sitemaps error?

 *  Resolved [dianapatrizia](https://wordpress.org/support/users/dianapatrizia/)
 * (@dianapatrizia)
 * [3 years, 10 months ago](https://wordpress.org/support/topic/sitemaps-error-4/)
 * Hi there, I recently switched from a Jetpack-generated sitemap to use one generated
   by Yoast.
 * I thought everything was OK but I’m seeing this error in Ahrefs:
 * The format of the following sitemaps is invalid:
    [https://farawayplaces.co/](https://farawayplaces.co/)
 * I don’t know why it thinks that is my sitemap file, as Yoast seems to have created
   a new robots.txt here:
    [https://farawayplaces.co/robots.txt](https://farawayplaces.co/robots.txt)
 * That correctly identifies the primary sitemap file as:
    Sitemap: [https://farawayplaces.co/sitemap.xml](https://farawayplaces.co/sitemap.xml)
 * Thank you in advance for your help!
 * The page I need help with: _[[log in](https://login.wordpress.org/?redirect_to=https%3A%2F%2Fwordpress.org%2Fsupport%2Ftopic%2Fsitemaps-error-4%2F%3Foutput_format%3Dmd&locale=en_US)
   to see the link]_

Viewing 4 replies - 1 through 4 (of 4 total)

 *  [Jeroen Rotty](https://wordpress.org/support/users/jeroenrotty/)
 * (@jeroenrotty)
 * [3 years, 10 months ago](https://wordpress.org/support/topic/sitemaps-error-4/#post-15837692)
 * Hey [@dianapatrizia](https://wordpress.org/support/users/dianapatrizia/),
 * Thank you for reaching out.
 * Can you let us know more about what Ahrefs has told you that was invalid? I checked
   the sitemap_index.xml Yoast sitemap, but can’t seem to find anything invalid 
   about it.
 * I do see in your robots.txt that there is a news sitemap:
    `Sitemap: https://
   farawayplaces.co/news-sitemap.xml`
 * However, that URL is not functioning and redirects to your homepage. If you don’t
   have a news sitemap, it’s better to remove that line from your robots.txt
 *  [devnihil](https://wordpress.org/support/users/devnihil/)
 * (@devnihil)
 * [3 years, 10 months ago](https://wordpress.org/support/topic/sitemaps-error-4/#post-15865202)
 * We are going ahead and marking this issue as resolved due to inactivity. If you
   require any further assistance please create a new issue.
 *  Thread Starter [dianapatrizia](https://wordpress.org/support/users/dianapatrizia/)
 * (@dianapatrizia)
 * [3 years, 10 months ago](https://wordpress.org/support/topic/sitemaps-error-4/#post-15865370)
 * I just want to say for anyone with a similar query in the future – the redirect
   to the homepage was what was causing the ahrefs error. Thank you Yoast team for
   clearing it up!
 *  [brenontheroad](https://wordpress.org/support/users/brenontheroad/)
 * (@brenontheroad)
 * [3 years, 6 months ago](https://wordpress.org/support/topic/sitemaps-error-4/#post-16233668)
 * Can you elaborate? What do you mean the redirect to the homepage? And how did
   you fix it? I’m having the same issue.

Viewing 4 replies - 1 through 4 (of 4 total)

The topic ‘Sitemaps error?’ is closed to new replies.

 * ![](https://ps.w.org/wordpress-seo/assets/icon-256x256.gif?rev=3419908)
 * [Yoast SEO - Advanced SEO with real-time guidance and built-in AI](https://wordpress.org/plugins/wordpress-seo/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/wordpress-seo/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/wordpress-seo/)
 * [Active Topics](https://wordpress.org/support/plugin/wordpress-seo/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/wordpress-seo/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/wordpress-seo/reviews/)

## Tags

 * [sitemaps](https://wordpress.org/support/topic-tag/sitemaps/)

 * 4 replies
 * 4 participants
 * Last reply from: [brenontheroad](https://wordpress.org/support/users/brenontheroad/)
 * Last activity: [3 years, 6 months ago](https://wordpress.org/support/topic/sitemaps-error-4/#post-16233668)
 * Status: resolved