Hello,
We apologize for the issue you are facing with your sitemaps not updating to include all created pages. Thank you for providing your sitemap index URL and site URL, as this information is helpful in diagnosing the problem.
Here are a few potential reasons why some of your posts and pages might not be appearing in the sitemaps:
-
Custom Canonicals: If you have set custom canonical URLs for your posts, those posts will not appear in the sitemap. Rank Math includes a self-referencing canonical by default, so if you want all your posts to show up, consider removing any custom canonicals.
-
Post Status: Ensure that the posts and pages you want to include in the sitemap are published and not set to draft or private status.
-
Sitemap Settings: Check your Rank Math settings to ensure that all post types you want included in the sitemap are enabled. You can do this by going to Rank Math SEO → Sitemap Settings and verifying that the relevant post types are checked.
-
Plugin Conflicts: Sometimes, other plugins can conflict with Rank Math’s functionality. You might want to check for any plugin conflicts using the Health Check plugin.
-
Caching Issues: If you are using a caching plugin, clear your cache to ensure that the latest changes are reflected in your sitemap.
If you’ve already checked these points and the issue persists, please reply to this ticket with any additional details or errors you might be encountering, and a human agent from our support team will assist you further.
Thank you for your patience, and we hope to resolve this issue for you soon!
Sources:
Rank Math Sitemap Issues and Their Fixes » Rank Math
I’ve checked everything you mentioned and haven’t come across any reasons my pages and posts would be excluded from their sitemaps.
Hello,
In this case, please follow these steps to flush your sitemap cache:
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. Disable the transient cache for the sitemap by applying this filter. This will make sure that your XML sitemap always reflects the latest changes on your site:
/**
* Filter if XML sitemap transient cache is enabled.
*
* @param boolean $unsigned Enable cache or not, defaults to true
*/
add_filter( 'rank_math/sitemap/enable_caching', '__return_false');
If you’re not sure how to add this code, you can follow this guide:
https://rankmath.com/kb/wordpress-hooks-actions-filters/
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.