Sitemap Issue

#943049
Viewing 2 replies - 1 through 2 (of 2 total)
  • Hello,

    We apologize for the issue you are facing with your sitemap. It seems that Google Search Console is indicating that your sitemap is being read as an HTML page instead of the expected XML format. Here are some steps you can take to troubleshoot and resolve this issue:

    1. Check the Sitemap URL: Ensure that you are submitting the correct sitemap URL to Google. The correct URL should be `https://rankmath.com/kb/fix-sitemap-issues/#unsupported. If this URL opens your website instead of the sitemap, it indicates a problem with the sitemap generation.

    2. Flush Permalinks: Sometimes, flushing permalinks can resolve issues with sitemap accessibility. You can do this by going to your WordPress dashboard, navigating to Settings → Permalinks, and simply clicking Save Changes without making any modifications.

    3. Check for Plugin Conflicts: There may be a conflict with another plugin that is affecting the sitemap. You can use the Health Check plugin to identify any potential conflicts.

    4. Review .htaccess or Nginx Configuration: If you are using an Apache server, ensure that your .htaccess file has the correct rewrite rules for Rank Math sitemaps. If you are using Nginx, check your Nginx configuration file for the appropriate rewrite rules as well. Here’s an example of what you might need to add:

      For Apache:

      # START of Rank Math Sitemap Rewrite Rules
      RewriteEngine On
      RewriteBase /
      RewriteRule ^sitemap_index.xml$ /index.php?sitemap=1 [L]
      RewriteRule ^([^/]+?)-sitemap([0-9]+)?.xml$ /index.php?sitemap=$1&sitemap_n=$2 [L]
      RewriteRule ^([a-z]+)?-?sitemap.xsl$ /index.php?xsl=$1 [L]
      # END of Rank Math Sitemap Rewrite Rules

      For Nginx:

      # START Nginx Rewrites for Rank Math Sitemaps
      rewrite ^/sitemap_index.xml$ /index.php?sitemap=1 last;
      rewrite ^/([^/]+?)-sitemap([0-9]+)?.xml$ /index.php?sitemap=$1&sitemap_n=$2 last;
      rewrite ^/([a-z]+)?-sitemap.xsl$ /index.php?xsl=$1 last;
      # END Nginx Rewrites for Rank Math Sitemaps
    5. Validate Your Sitemap: Use a tool like the Validate XML Sitemap to check if your sitemap is correctly configured. This can help identify any specific errors in the sitemap structure.

    If you have followed these steps and are still experiencing issues, please reply to this ticket, and a human agent from the Rank Math Support team will take over and assist you further. Thank you for raising this concern!

    Sources:
    Rank Math Sitemap Issues and Their Fixes » Rank Math
    Troubleshooting the “Couldn’t Fetch” Error in Google Search Console » Rank Math

    Hello,

    Thank you for contacting us and sorry for any inconvenience that might have been caused due to that.

    Please try to follow the steps below and see if that works for you:

    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, remove all the submitted sitemap, and resubmit only the /sitemap_index.xml in the Search Console.

    Let us know how it goes. Looking forward to helping 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 2 replies - 1 through 2 (of 2 total)

The ticket ‘Sitemap Issue’ is closed to new replies.