Hello,
Thank you for contacting Rank Math, and sorry for any inconvenience caused.
The sitemap is loading fine on ?sitemap=1. Check the screencast in sensitive data section.
This means that the redirection in the server configuration is not correctly set up and you need to update it with the following: https://rankmath.com/kb/fix-sitemap-issues/#apache-error
After adding that, the redirection should work correctly and the sitemap will load on the expected URL.
If you are not sure, you can get in touch with the web host and ask them to add the rules.
Don’t hesitate to get in touch if you have any other questions.
Hi
I have added it successfully but it is not working still
Website was on apache web server before on cpanel and was not working but I transferred to lightspeed website server and still not working even I added mentioned code as well
any help will be appreciated
Thank you
Hello,
Could you please follow these steps to flush your sitemaps cache (if not yet)?
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/
Let us know how this goes.
Thank you.
Hi
Its still not worked
I tried everything available over the internet but nothing worked
could you please check from your side
Hello,
Please also share the WordPress logins of the website so that we can have a closer look.
Looking forward to helping you.
Thank you.
Sure here is wp login details
[moved to sensitive data section]
looking forward on this
Hello,
I checked your .htaccess file and a rewrite had already been applied to fix your sitemaps not displaying correctly. However the redirect is not working. Please contact your host for help enabling the following rewrites that area already in your htaccess file:
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]
Once the rewrite rules start working your sitemaps should be displayed correctly.
Hope that helps. Please let us know if you have questions.
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.