Sitemap could not be read – 404 error

#370001
  • Resolved Robert Runyon
    Rank Math free

    Hello, when I submit my sitemap to Google Search Console, it tells me that it couldn’t be read and gives a 404 error.

    Can you please explain to me what I am doing wrong and how I can fix it?

    I want all of my website pages & posts that are indexed to be included without the ones that are no-indexed.

    How can I make this happen?

Viewing 3 replies - 1 through 3 (of 3 total)
  • Anas
    Rank Math business

    Hello,

    Thank you for contacting Rank Math, and sorry for any inconvenience caused.

    Can you please follow these steps?
    1. Flush the Sitemap cache by following this video screencast:
    https://i.rankmath.com/pipRDp

    2. Exclude the Sitemap files of the Rank Math plugin in your caching plugin. The cache could be via a plugin or from the server. For plugins or Cloudflare, please follow this article:
    https://rankmath.com/kb/exclude-sitemaps-from-caching/

    Once done, clear your website cache and resubmit the sitemap in the Search Console.

    Looking forward to helping you.

    I have no way to edit the htc access and complete the second step – how do I edit the htc access?

    Anas
    Rank Math business

    Hello,

    If you do not have an option to edit .htaccess, you can exclude the sitemaps from caching in your caching plugin.

    If you are not using any caching plugin, you can add this filter in the theme’s functions.php file:

    add_filter( 'rank_math/sitemap/enable_caching', '__return_false');
    

    Here is a guide you can follow to add the filter:
    https://rankmath.com/kb/wordpress-hooks-actions-filters/#functions-php-file

    Hope that helps.

    Thank you.

    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.

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

The ticket ‘Sitemap could not be read – 404 error’ is closed to new replies.