Documentation → Administrator Guides

Advanced Settings

Exclusion rules, performance tuning, and debug options.

Accessing Advanced Settings

Navigate to Sitemap → Advanced in your WordPress dashboard. This page provides fine-grained control over what content appears in your sitemap and how it’s generated.

Note: Advanced settings require the manage_options capability. Only administrators can access this page.


Content Exclusions

Exclude specific posts, pages, or products from appearing in your sitemap. Useful for landing pages, thank-you pages, or content you don’t want indexed.

Exclude by Post ID

Enter post IDs separated by commas to exclude specific content:

Field: Excluded Post IDs

Format: 123, 456, 789

Accepts: Posts, pages, products, and custom post types

Finding Post IDs

To find a post’s ID:

  1. Go to Posts or Pages in your dashboard
  2. Hover over the item you want to exclude
  3. Look at the URL in your browser’s status bar
  4. Find the number after post= (e.g., post=123)

Common Exclusion Scenarios

Content TypeWhy Exclude
Thank You pagesPost-conversion pages shouldn’t be indexed
Landing pagesPPC landing pages may have noindex requirements
Internal pagesStaff directories, internal resources
Duplicate contentPrint versions, alternate formats
Staging contentTest pages not ready for indexing

Taxonomy Exclusions

Exclude entire categories, tags, or custom taxonomy terms. All posts assigned to excluded terms will be removed from the sitemap.

Exclude by Category

Select categories to exclude from the dropdown list. Posts in these categories won’t appear in the sitemap.

Example Categories to ExcludeReason
InternalCompany-only content
ArchiveOutdated content kept for reference
Draft IdeasUnpublished concept posts
UncategorizedDefault category with mixed content

Exclude by Tag

Enter tag slugs separated by commas:

noindex, internal-use, legacy-content

Warning: Taxonomy exclusions cascade. If a post belongs to multiple categories and one is excluded, the post will still be excluded from the sitemap.


Performance Tuning

Optimize sitemap generation for your server’s capabilities and site size.

Items Per Sitemap

Controls how many URLs are included in each sitemap file before splitting into multiple files.

SettingValue
Default1,000 URLs
Minimum100 URLs
Maximum50,000 URLs (protocol limit)

Recommended Values by Site Size

Site SizeContent CountRecommendedWhy
Small<1,000 pages1,000 (default)Single sitemap file
Medium1,000-10,0002,500-5,000Balance files vs. size
Large10,000-50,00010,000-25,000Reduce HTTP requests
Enterprise>50,00025,000-50,000Maximize efficiency

Memory Limit Considerations

Higher values require more memory during generation:

Items Per SitemapApprox. MemoryShared Hosting
1,000~32 MBSafe
5,000~64 MBUsually safe
10,000~128 MBMay need upgrade
25,000~256 MBVPS recommended
50,000~512 MBDedicated server

Tip: If you experience timeout errors, reduce the Items Per Sitemap value. More smaller files are better than failed generation.

Query Batch Size

Controls how many posts are queried at once during generation. Lower values reduce peak memory usage.

SettingValue
Default500 posts per batch
Low memory100-200 posts
High performance1,000+ posts

Manual Regeneration

Force a complete sitemap rebuild, bypassing all caches.

When to Regenerate

  • After bulk importing content
  • After changing permalink structure
  • After modifying exclusion rules
  • After restoring from backup
  • When troubleshooting sitemap issues

Regeneration Options

OptionAction
Regenerate AllClears cache and rebuilds all sitemaps
Regenerate PostsRebuilds only the post sitemap
Regenerate PagesRebuilds only the page sitemap
Regenerate ProductsRebuilds only the product sitemap

To regenerate:

  1. Go to Sitemap → Advanced
  2. Scroll to Manual Controls section
  3. Click desired regeneration button
  4. Wait for success confirmation

Debug Mode

Enable detailed logging to troubleshoot sitemap generation issues.

What Gets Logged

Log EntryInformation
Generation startTimestamp, sitemap type
URL providerProvider name, URLs returned
Exclusions appliedPost IDs excluded, reasons
Cache operationsHits, misses, writes
Memory usagePeak memory during generation
TimingDuration of each phase
ErrorsAny exceptions or warnings

Enabling Debug Mode

  1. First, enable WordPress debug logging in wp-config.php:
define('WP_DEBUG', true);
define('WP_DEBUG_LOG', true);
define('WP_DEBUG_DISPLAY', false);
  1. Go to Sitemap → Advanced
  2. Check Enable Debug Mode
  3. Click Save Settings
  4. Trigger a sitemap request or regeneration
  5. View logs at /wp-content/debug.log

Sample Debug Output

[10-Jan-2026 14:32:15] Developer Sitemap: Starting generation for type 'post'
[10-Jan-2026 14:32:15] Developer Sitemap: PostUrlProvider returned 1,247 URLs
[10-Jan-2026 14:32:15] Developer Sitemap: Excluded 3 posts by ID: 123, 456, 789
[10-Jan-2026 14:32:15] Developer Sitemap: Excluded 12 posts by category: 'internal'
[10-Jan-2026 14:32:16] Developer Sitemap: Final URL count: 1,232
[10-Jan-2026 14:32:16] Developer Sitemap: Generation complete in 0.847s
[10-Jan-2026 14:32:16] Developer Sitemap: Peak memory: 48.2 MB
[10-Jan-2026 14:32:16] Developer Sitemap: Cache written successfully

Important: Disable debug mode on production sites after troubleshooting. It can grow the log file quickly and may expose internal paths.


Best Practices

Exclusion Strategy

  • Be intentional — Only exclude content you genuinely don’t want indexed
  • Use categories — Create an “Internal” or “No Index” category for bulk management
  • Document exclusions — Keep a record of why specific content is excluded
  • Review periodically — Check exclusions quarterly for relevance

Performance Optimization

  • Start conservative — Begin with default values and increase if stable
  • Monitor memory — Check server logs for memory warnings
  • Enable caching — Always use caching in production
  • Test changes — After adjusting, verify sitemap still generates correctly

Settings Summary

SettingDefaultRecommended Range
Excluded Post IDsEmptyAs needed
Excluded CategoriesNoneAs needed
Excluded TagsEmptyAs needed
Items Per Sitemap1,0001,000–25,000
Query Batch Size500100–1,000
Debug ModeOffOff (production)