Support » Plugin: Yoast SEO » XML Sitemap Parsing Error Line 1 (Not caused by whitespace)

  • Resolved mattpdemers

    (@mattpdemers)


    Hi,
    I’ve used Yoast for a long time and never had this issue. Reviewed the support forum and your troubleshooting and can’t find anything other than the whitespace issue some have but have viewed source code and confirmed that is not the case.

    Everything looks good to me, but I have an error in search console that reads the following:

    “Sitemap can be read, but has errors
    Parsing error
    1 instance
    We were unable to read your Sitemap. It may contain an entry we are unable to recognize. Please validate your Sitemap before resubmitting.
    Examples
    Line 1”

    At first I thought it was because sitemap.xml, re-directs to sitemap-index.xml but I submitted the url for the sitemap and received the same error.

    Individual sitemaps for pages, posts and products validate.

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

Viewing 4 replies - 1 through 4 (of 4 total)
  • Plugin Support amboutwe

    (@amboutwe)

    The featured_item-sitemap.xml has no real content and is missing a last modified date. Please disable this individual sitemap until you have added content for this section. The sitemap index can be customized under SEO > Search Appearance.

    Posts, pages, and other custom post types can be customized under the ‘Content Types’ tab. Removing a post type from the search results will also remove them from the sitemap. Showing them in the search results will show them in the sitemap.

    Learn more in the following article: How to Customize the Sitemap Index

    • This reply was modified 2 years, 1 month ago by amboutwe.
    • This reply was modified 2 years, 1 month ago by amboutwe.
    Thread Starter mattpdemers

    (@mattpdemers)

    Hi,
    Thanks for the reply Amboutwe – I have since turned off the featured_item-sitemap.xml – however the problem still persists – line 1 of the general sitemap (sitemap_index.xml) will not validate. When I ran it through a validation check on XML-sitemaps.com the error message is:

    Incorrect http header content-type: “text/html; charset=UTF-8” (expected: “application/xml”)

    Any suggestions?

    Plugin Support amboutwe

    (@amboutwe)

    This typically occurs when the server incorrectly sets the content-type to html instead of xml; likely during the redirect (if the error only occurs when checking the sitemap.xml instead of sitemap_index.xml). Your webhost should be able to help track the cause and resolve the incorrect content-type.

    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 ‘XML Sitemap Parsing Error Line 1 (Not caused by whitespace)’ is closed to new replies.