Back to Community

Troubleshooting Empty or Missing Sitemaps in XML Sitemap Generator for Google

48 threads Sep 16, 2025 PluginXml sitemap generator for google

Content

Encountering an empty sitemap or a missing sitemap file is a common issue reported by users of the 'XML Sitemap Generator for Google' plugin. This problem can prevent search engines from properly indexing your site and often manifests as a blank page when visiting yoursite.com/sitemap.xml or specific sitemap files like sitemap-pt-postname.xml being empty. Based on community reports and fixes, here’s a breakdown of why this happens and the most effective solutions.

Why Does This Happen?

The root cause often lies in one of a few key areas:

  • Plugin Conflicts: Other plugins, especially SEO plugins like Yoast SEO or Jetpack that also generate sitemaps, can cause conflicts.
  • Physical File Conflicts: A lingering physical sitemap.xml or sitemap.xml.gz file in your website's root directory can override the dynamic sitemap generated by the plugin.
  • Custom Post Types & Taxonomies: A known bug in older plugin versions incorrectly handled custom taxonomies and some post types, leading to empty sitemap files for those content types.
  • Permalink Structure: An incorrect or unflushed permalink structure can break the plugin's URL routing.
  • Code Errors: Whitespace or errors in a theme's functions.php file can corrupt the XML output, resulting in a blank page.

Common Solutions to Try

1. Check for and Delete Physical Sitemap Files

This is the most frequent solution. The plugin generates sitemaps dynamically, but if an old, physical file exists on your server, it will be served instead, often appearing blank.

  1. Access your website's root directory via FTP or your hosting provider's file manager.
  2. Look for and delete any files named sitemap.xml, sitemap.xml.gz, or any file starting with sitemap-.
  3. Return to your WordPress admin area and try to access the sitemap again. The plugin should now generate it dynamically.

2. Resolve Plugin Conflicts

If you have multiple sitemap plugins active, you must choose one.

  1. Go to Plugins → Installed Plugins.
  2. If you have Yoast SEO, Jetpack, or another SEO plugin, navigate to its settings and disable its sitemap generation feature. This is usually found in the 'XML Sitemaps' or 'Webmaster Tools' section of the other plugin's settings.
  3. If you wish to use 'XML Sitemap Generator for Google', ensure all other sitemap plugins are deactivated entirely.

3. Flush Your Permalink Structure

This refreshes WordPress's URL rewrite rules, which the plugin relies on.

  1. Go to Settings → Permalinks.
  2. Without making any changes, simply click the "Save Changes" button at the bottom of the page.

4. Review Custom Content Type Settings

If sitemaps for specific custom post types or taxonomies (like categories) are empty, check your plugin settings.

  1. Go to Settings → XML-Sitemap.
  2. Under "Sitemap Content," ensure the checkboxes for your custom post types and taxonomies are selected.
  3. If the problem persists specifically for categories, a temporary workaround mentioned in the community is to deselect "Include categories" to prevent the generation of an empty file, though this is not an ideal long-term solution.

5. Check for Code Errors

A blank XML file can sometimes be caused by a PHP error or whitespace in your theme's code.

  1. Temporarily switch to a default WordPress theme like Twenty Twenty-Four.
  2. Check if the sitemap works. If it does, the error is likely in your regular theme's code, often in the functions.php file.
  3. Enable WP_DEBUG in your wp-config.php file to see if any errors are logged when the sitemap is generated.

When to Suspect a Bug

If you have tried all the above and your sitemap for a custom taxonomy remains empty, you may be experiencing a bug that was identified and fixed by the community. The issue involved the plugin misidentifying custom taxonomies. The 'XML Sitemap Generator for Google' team has indicated this fix is included in a subsequent release. Ensuring your plugin is updated to the latest version is the best course of action.

By methodically working through these steps, most users can resolve issues with empty or missing sitemaps and get their XML sitemap functioning correctly again.

Related Support Threads Support