After installing rankingmat my sitemap no longer works

#1089911
  • Resolved RAF
    Rank Math free

    After installing rankingmat my sitemap no longer works… before it was sitemap.xml now it redirects to /sitemap_index.xml and goes to the 404 page, how can I fix this? If it doesn’t work I’ll use AIO. Can you help? Thank you

Viewing 4 replies - 1 through 4 (of 4 total)
  • Hello,

    We apologize for the issue you are facing with your sitemap after installing Rank Math. It sounds like there may be a configuration issue or a conflict that is causing the 404 error for your sitemap.

    Here are some steps you can take to troubleshoot and potentially fix the issue:

    1. Check Your Sitemap URL: Ensure that you are using the correct sitemap URL, which should be https://rankmath.com/blog/backup-wordpress-site/. Replaceyourdomain.com` with your actual domain name.

    2. Validate Your Sitemap: Use the Validate XML Sitemap tool to check if your sitemap is correctly configured. This can help identify any issues with the sitemap itself.

    3. Check for Plugin Conflicts: Sometimes, other plugins can conflict with Rank Math. You can use the Health Check plugin to identify any conflicts.

    4. Rewrite Rules: If you are using an Apache server, ensure that your .htaccess file has the correct rewrite rules for Rank Math. You can add the following code:

      # 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
    5. Nginx Configuration: If you are using Nginx, ensure that your configuration file has the appropriate rewrite rules as well:

      # 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
    6. Reset Settings: If all else fails, you might consider resetting your Rank Math settings to default. You can do this from the settings page in Rank Math.

    If these steps do not resolve the issue, please reply to this ticket with your site URL so we can assist you further. Additionally, if you prefer a more hands-on approach, we recommend our professional setup service available at Rank Math Services, which requires a PRO subscription. This service ensures your plugin setup is fully correct and adheres to the latest SEO standards.

    Thank you for raising this concern, and we hope to help you get your sitemap working again!

    Sources:
    Rank Math Sitemap Issues and Their Fixes » Rank Math
    How to Configure Sitemaps in Rank Math – Best Settings and Tips
    Troubleshooting the “Couldn’t Fetch” Error in Google Search Console » Rank Math

    Hello,

    That’s completely normal as Rank Math uses /sitemap_index.xml as the main sitemap.

    It’s fully supported by Google and other search engines. Please head to your Google Search Console, remove the old sitemap, and submit the new /sitemap_index.xml instead. That should fix the issue.

    Don’t hesitate to get in touch with us if you have any other questions.

    RAF
    Rank Math free

    Hi Jeremi, please visit https://www.digitalentity.it//sitemap_index.xml

    now the sitemap is broker with 404 page error…. how we can solve? Thank you

    Hello,

    Please follow the steps below:

    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/

    3. Apply the following filter code to your site.

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

    Here’s how you can add filter to your WordPress site:https://rankmath.com/kb/wordpress-hooks-actions-filters/

    Let us know how that goes. Looking forward to helping you.

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

You must be logged in to reply to this ticket.