Fix Your Sitemap for Drupal

Updated April 2026·By SitemapFixer Team

Drupal 9 and 10 sites rely on the Simple XML Sitemap module to generate sitemap.xml. Content type settings, taxonomy term bundles, and language variants determine what gets indexed and what gets buried.

Analyze your Drupal sitemap nowTry Sitemap Fixer Free

Drupal sitemaps go wrong when content types are enabled by default, when taxonomy pages are exposed without curation, or when Views-generated listings bloat the feed. And unlike WordPress, Drupal doesn't ship a sitemap with core - you pick a module, configure it per-bundle, and remember to regenerate on content changes.

Audited a Drupal 10 publisher last month with 9,200 articles. The sitemap had 31,000 URLs. Breakdown: 9,200 articles (expected), 6,800 taxonomy term pages (mostly empty tag pages), 11,000 "Basic page" nodes that had been used as components inside other pages, and 4,000 Views listing URLs. Turning off everything except Article and Product content types dropped the sitemap to 9,800 URLs overnight.

Simple XML Sitemap vs XML Sitemap

Two modules, similar names:

Common Drupal Sitemap Issues

Install and configure Simple XML Sitemap

# Install
composer require drupal/simple_sitemap
drush en simple_sitemap -y

# Regenerate
drush simple-sitemap:generate

# Generate a specific variant only
drush simple-sitemap:generate --variants=default

# Clear cache so the new sitemap is served
drush cr

# View counts per URL (sanity check)
curl -s https://yoursite.com/sitemap.xml | grep -c '<url>'

Content type filtering and path aliases

Go to /admin/config/search/simplesitemap/entities and enable only the bundles that should be indexable. Typical choices:

Path aliases: install drupal/pathauto and set patterns for each bundle. Simple XML Sitemap uses the aliased URL if pathauto is active - otherwise it emits /node/123 which is awful for rankings and worse for crawlability.

Multilingual and hreflang

With locale and content_translation enabled, Simple XML Sitemap emits one URL per language variant. To add xhtml:link alternates, enable the hreflang submodule shipped in simple_sitemap. Each translated node then lists all its language alternates inside the same <url> element. Verify in GSC's International Targeting report that alternates are detected without errors.

Step-by-Step Fix Guide

  1. Install via composer require drupal/simple_sitemap and enable with drush
  2. At /admin/config/search/simplesitemap/entities, enable only public-landing-page bundles
  3. Set per-bundle priority and changefreq (Article 0.8 weekly, Term 0.3 monthly, Product 0.7 weekly)
  4. Install pathauto and configure patterns so entity URLs use aliases
  5. Under Views, disable sitemap inclusion on admin and internal listings
  6. For multilingual, enable the hreflang submodule
  7. Run drush simple-sitemap:generate then drush cr
  8. Verify with curl https://yourdomain.com/sitemap.xml and inspect a few URLs
  9. Submit to Google Search Console

Frequently Asked Questions

Simple XML Sitemap vs XML Sitemap - which Drupal module?
Simple XML Sitemap (drupal/simple_sitemap) is actively maintained and Drupal 10 compatible. The older XML Sitemap module (drupal/xmlsitemap) is legacy and only recommended if you're on Drupal 7. Start with Simple XML Sitemap on any new site.
Why are /taxonomy/term/42 URLs in my sitemap instead of aliases?
Pathauto isn't applied. Ensure pathauto is enabled and taxonomy term patterns are set. Then regenerate with drush simple-sitemap:generate so aliased URLs replace raw entity paths.
How do I split a Drupal sitemap over 50k URLs?
Simple XML Sitemap shards automatically at 2,000 URLs per file by default, but you can raise it. For very large sites, create multiple sitemap variants under /admin/config/search/simplesitemap/variants. Each gets its own URL and its own coverage report in GSC.
Analyze your Drupal sitemap
Find all issues in your sitemap - free, no credit card needed
Analyze My Sitemap Free
Other platform guides