An XML sitemap is a machine-readable list of the canonical URLs that a website wants search engines to discover and consider for crawling. WordPress 5.5 and later usually creates one automatically at /wp-sitemap.xml; SEO plugins may use /sitemap_index.xml instead. A sitemap helps discovery but does not guarantee indexing or rankings.

For most WordPress sites, the quickest solution is to open https://yourdomain.com/wp-sitemap.xml. If an SEO plugin controls the site’s sitemaps, use that plugin’s sitemap index instead. After confirming that the sitemap contains only public, canonical URLs intended for search, submit the index in Google Search Console.

Key takeaways

  • WordPress core has generated XML sitemaps since WordPress 5.5, normally at /wp-sitemap.xml.
  • An XML sitemap helps search engines discover URLs, but it does not force crawling, indexing, ranking, or inclusion in search results.
  • Google’s current guidance says a sitemap may be unnecessary for a small, well-linked site with roughly 500 or fewer indexable pages.
  • Use one authoritative sitemap system: WordPress core or one SEO plugin, not several overlapping generators.
  • Submit the sitemap index—not normally every child sitemap—to Google Search Console.
  • A good sitemap contains final, public, canonical, indexable URLs rather than redirects, deleted pages, duplicate URLs, or thin archive pages.

What is an XML sitemap?

An XML sitemap is a machine-readable file that lists important URLs on a website for search-engine crawlers. XML stands for Extensible Markup Language, a structured text format that allows software to read information consistently.

The sitemap is primarily for search engines, not for human visitors. An HTML sitemap, by contrast, is a human-facing webpage containing links that can help visitors navigate a site. An XML sitemap and an HTML sitemap serve different purposes, and an XML sitemap does not replace useful navigation or internal links.

According to Google’s sitemap overview, a sitemap can help search engines discover URLs and may also provide information such as when a page was last modified. Supported sitemap extensions can describe images, videos, news content, or alternate language versions.

What does a sitemap entry look like?

A basic XML sitemap contains a URL set and one or more URL entries. Each entry normally includes a fully qualified absolute URL inside a <loc> element and may include a <lastmod> date.

<?xml version="1.0" encoding="UTF-8"?>
<urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9">
  <url>
    <loc>https://www.example.com/example-page/</loc>
    <lastmod>2026-08-18</lastmod>
  </url>
</urlset>

Use UTF-8 encoding and absolute URLs. The <lastmod> value should be accurate and consistently verifiable; do not update it merely to make a page appear fresh. Google ignores <priority> and <changefreq>, so those values do not tell Google which pages to rank or crawl first. Google’s detailed sitemap creation documentation explains the supported format and limits.

What is the difference between a sitemap and a sitemap index?

A sitemap can be one file containing URLs, or it can be a sitemap index that points to multiple child sitemaps. A WordPress sitemap index might link to separate files for posts, pages, categories, tags, authors, products, or custom post types.

Asset What it contains Typical WordPress example
Individual sitemap A list of URLs for one content group post-sitemap.xml
Sitemap index Links to multiple child sitemaps wp-sitemap.xml or sitemap_index.xml
HTML sitemap Human-readable links for visitors A normal WordPress page

Google’s general sitemap limit is 50,000 URLs or 50 MB uncompressed per sitemap. According to Google’s sitemap documentation (current guidance accessed August 18, 2026), larger sites should split URLs across multiple files and use a sitemap index. WordPress core uses a lower default of 2,000 entries per child sitemap.

What does an XML sitemap do for SEO?

An XML sitemap primarily improves URL discovery: it gives search engines a structured list of pages that the site considers important. The sitemap supplements discovery through internal links, external links, browser navigation, and other crawling systems.

A sitemap does not guarantee that Google or another search engine will crawl every listed URL. Crawling is the process of fetching and processing a URL; indexing is the separate decision about whether that URL belongs in a search index; ranking determines where an indexed page appears for a query. A sitemap supports the first stage but does not override the other decisions.

A sitemap also does not replace internal linking, canonical tags, useful content, correct HTTP status codes, or appropriate robots and indexing controls. A page that is listed in a sitemap can still be excluded because it is duplicated, low quality, inaccessible, redirected, marked noindex, or otherwise unsuitable for indexing.

Who benefits most from an XML sitemap?

XML sitemaps are particularly useful for new, large, frequently changing, poorly internally linked, multilingual, or media-heavy websites. Ecommerce stores, news sites, sites with many categories or custom post types, and sites with orphaned pages can also benefit from a structured discovery signal.

According to Google’s sitemap guidance (current guidance accessed August 18, 2026), a sitemap may be unnecessary for a small site with roughly 500 or fewer pages that the owner wants indexed when important pages are comprehensively linked internally. A valid automatically generated sitemap is still reasonable for such a site because it requires little ongoing work.

Does WordPress automatically create an XML sitemap?

Yes. WordPress core automatically generates a basic XML sitemap for WordPress 5.5 and later. The normal sitemap index URL is:

https://yourdomain.com/wp-sitemap.xml

The WordPress core sitemap is generated dynamically, so wp-sitemap.xml is normally not a physical file that you upload to the website. WordPress core also references its sitemap index in generated robots.txt output. The WordPress core announcement describes the feature introduced in WordPress 5.5.

Core can generate sitemaps for public, publicly queryable content types and taxonomies, including standard posts, pages, eligible custom post types, categories, tags, author archives, and other site content subject to configuration and developer filters. The exact URLs included depend on the site’s settings, theme, plugins, and custom code.

What are the limitations of the WordPress core sitemap?

WordPress core provides basic URL discovery rather than a complete technical SEO system. Core does not natively provide every specialized sitemap extension, including dedicated image, video, and news sitemap functionality. Core also offers fewer beginner-friendly controls for excluding individual content types, taxonomies, archives, or other URL groups.

Core is usually sufficient for a small or straightforward site whose owner needs a basic sitemap. An SEO plugin may be more suitable when the site also needs integrated controls for indexability, metadata, schema, redirects, custom exclusions, or specialized search features. Installing a plugin solely to obtain a sitemap is usually unnecessary if /wp-sitemap.xml already works correctly.

How do you find your WordPress sitemap?

Check the standard WordPress endpoint first, then check common SEO-plugin endpoints and the site’s robots.txt file.

  1. Open https://yourdomain.com/wp-sitemap.xml.
  2. If an SEO plugin is active, try https://yourdomain.com/sitemap_index.xml.
  3. You can also test https://yourdomain.com/sitemap.xml, but do not assume that this is the correct WordPress URL.
  4. Open https://yourdomain.com/robots.txt and look for a Sitemap: line.

Typical references look like this:

Sitemap: https://www.example.com/wp-sitemap.xml

or:

Sitemap: https://www.example.com/sitemap_index.xml

A site should not be expected to use every endpoint above. The working endpoint containing the intended URLs is the endpoint to submit. If both /wp-sitemap.xml and /sitemap_index.xml work, determine whether an SEO plugin has replaced or extended WordPress core before choosing one.

The WordPress core sitemap documentation explains how WordPress registers sitemap providers and exposes the sitemap reference through generated robots output.

How do you create a sitemap in WordPress without a plugin?

You normally do not need to manually create a sitemap in modern WordPress; WordPress core creates one automatically when the site runs WordPress 5.5 or later and sitemap output is available.

  1. Confirm that the site runs WordPress 5.5 or later.
  2. Visit https://yourdomain.com/wp-sitemap.xml.
  3. Confirm that the page loads and displays a sitemap index or XML content.
  4. Open the linked child sitemaps and review their URLs.
  5. Confirm that the site is not set to discourage search engines from indexing it.
  6. Submit wp-sitemap.xml in Google Search Console.

To check the WordPress visibility setting, open the WordPress Dashboard and go to Settings → Reading. Make sure Discourage search engines from indexing this site is not selected on a production website that should appear in search. This setting is not the only indexing control, so also review plugin settings, page-level noindex directives, robots rules, and server responses.

How do you create a sitemap with Yoast SEO?

Yoast SEO can generate and update a sitemap index alongside its broader SEO controls. The current Yoast documentation path is WordPress Dashboard → Yoast SEO → Settings → Site features; under Technical SEO, turn XML sitemaps on and select View the XML sitemap.

  1. Open the WordPress Dashboard.
  2. Select Yoast SEO.
  3. Open Settings, then Site features.
  4. Under Technical SEO, enable XML sitemaps.
  5. Select View the XML sitemap to identify the live sitemap index.
  6. Review the included post types, taxonomies, and archives before submitting the index.

The usual Yoast sitemap index is:

https://yourdomain.com/sitemap_index.xml

Yoast automatically updates its sitemap index as content is added, changed, or removed. Content types configured as noindex are excluded from Yoast’s sitemap output. Yoast notes that exact dashboard labels can change between plugin versions, so use the current documentation if the menu names differ. See Yoast’s XML sitemap documentation for the documented behavior.

Do not enable a second dedicated sitemap plugin just because Yoast is installed. If WordPress core, Yoast, another SEO plugin, or a manually uploaded file produces competing endpoints, choose one authoritative system and verify its contents.

Should you use Rank Math or All in One SEO for a sitemap?

Rank Math and All in One SEO are reasonable options for site owners who already want an integrated SEO suite with sitemap functionality, but neither is required merely to obtain a basic XML sitemap.

Approach Best fit Main advantage Main trade-off
WordPress core Small or straightforward sites Built in, automatically updated, and free of an extra plugin dependency Basic exclusions and no complete native image, video, or news sitemap extensions
Yoast SEO Sites already using Yoast or wanting integrated SEO controls Sitemap settings connect with indexability controls and the plugin updates the index automatically Adds a plugin dependency and may conflict with another sitemap generator
Rank Math Sites already committed to the Rank Math ecosystem Sitemap functionality is integrated with broader SEO configuration Adding it only for a sitemap is usually unnecessary
All in One SEO Sites already committed to the All in One SEO ecosystem Provides sitemap functionality as part of an integrated SEO suite Adding it only for a sitemap is usually unnecessary

Choose one SEO plugin if you use a plugin-based SEO system. Do not install multiple SEO plugins or sitemap plugins without understanding which one generates the live endpoint. Plugin features, menu labels, and paid-plan availability can change, so check the vendor’s current documentation before relying on a specific control.

What should a WordPress XML sitemap include?

A sitemap should include public, useful, canonical URLs that the site wants search engines to consider for indexing. Every listed URL should normally be accessible to crawlers, return a successful indexable response, and represent the final version of the page.

Usually include Usually exclude or review carefully
Canonical posts and pages intended for organic search Admin, login, cart, checkout, and account URLs
Public products and valuable custom post types Internal search-result pages
Useful categories or other taxonomies Thin author, date, or tag archives
Public URLs that return a successful indexable response Staging and development URLs
Pages that are internally linked or otherwise intentionally discoverable Redirecting URLs, 404 pages, duplicate parameter URLs, and filtered combinations without independent search value

The guiding rule is to include the URLs you want search engines to index, not every URL that WordPress can technically generate. Google recommends listing preferred canonical URLs and avoiding alternate or duplicate URLs in a sitemap. Read Google’s sitemap construction guidance when deciding how canonical and alternate URLs should be represented.

Avoid listing a URL that is simultaneously marked noindex, blocked in a way that prevents useful crawling, redirected, deleted, or non-canonical. A sitemap and the page’s canonical and indexability signals should tell a consistent story.

How do you submit a WordPress sitemap to Google Search Console?

Submit the sitemap index through Google Search Console after confirming that the index is publicly accessible and contains the correct URLs.

  1. Open Google Search Console.
  2. Select the correct verified property for the production site.
  3. Open Sitemaps in the left-hand navigation.
  4. Enter only the sitemap path, such as wp-sitemap.xml or sitemap_index.xml, in the submission field.
  5. Select Submit.
  6. Review the reported status and open the submitted sitemap later to inspect processing details and discovered URLs.

Submit the sitemap index rather than every child sitemap in normal circumstances. The index already references its child files and can update as content changes. Individual child submissions may be useful for targeted monitoring, but they are not normally necessary.

Search Console submission is a discovery signal and reporting mechanism, not a command to index every URL. Google can still reject, postpone, or exclude listed pages after evaluating accessibility, canonicalization, quality, duplication, and indexing directives. Google’s sitemap submission guidance covers the submission process and file requirements.

Should you add the sitemap to robots.txt?

Yes. Referencing the sitemap index in robots.txt gives crawlers another way to discover it, although the sitemap directive does not replace Search Console.

Sitemap: https://www.example.com/wp-sitemap.xml

Use the actual authoritative endpoint if an SEO plugin generates sitemap_index.xml instead. The Sitemap: directive is not a permission or blocking rule. robots.txt controls crawler access, while the sitemap identifies URLs that the site considers important. A sitemap can list URLs, but it cannot override a separate access restriction or guarantee indexing.

WordPress core normally adds its sitemap reference to generated robots output. If a static robots file, security plugin, CDN, or custom server rule replaces that output, check the live robots.txt response rather than assuming the reference exists.

How do you test and validate a WordPress sitemap?

A sitemap is valid for practical purposes when the sitemap file and its child files are publicly accessible, syntactically valid XML, and populated with the correct final URLs.

  • Open the sitemap URL in a browser and confirm that it loads.
  • Check that the response returns HTTP 200 rather than 404, 501, or another error.
  • Confirm that the response is valid XML and uses UTF-8.
  • Confirm that every listed URL is absolute and uses the production HTTPS hostname.
  • Check that URLs are canonical, final, public, and intended for organic search.
  • Remove or correct redirects, 404 URLs, blocked URLs, staging URLs, duplicates, and noindex URLs.
  • Open every child sitemap linked from the sitemap index.
  • Review the sitemap’s processing status and errors in Search Console.
  • Use Search Console’s URL Inspection tool separately for important pages; sitemap processing does not prove that individual pages were indexed.

A browser may show raw XML or an XML stylesheet. An unattractive or “ugly” display is not itself an error. Accessibility, syntax, response status, and URL quality matter more than visual presentation.

How do you fix common WordPress sitemap problems?

Why does the sitemap URL return 404?

A 404 usually means that the endpoint is wrong, sitemap generation is disabled or overridden, rewrite rules are stale, or a plugin, cache, security layer, or server configuration is interfering.

  1. Confirm the correct HTTPS domain and try /wp-sitemap.xml, /sitemap_index.xml, and the endpoint listed in robots.txt.
  2. In WordPress, open Settings → Permalinks and select Save Changes without changing the permalink structure. This refreshes rewrite rules.
  3. Check whether an SEO or sitemap plugin was recently deactivated or configured to disable XML sitemaps.
  4. Identify competing sitemap plugins and manually uploaded sitemap files.
  5. Purge page, object, CDN, and server caches.
  6. Inspect response headers and server or PHP error logs.
  7. Retest the endpoint in a browser and Search Console.

Do not try to delete wp-sitemap.xml through the media library or file manager as though it were a normal uploaded file. WordPress core generates the endpoint dynamically.

Why does the sitemap return HTTP 501?

WordPress core can require the PHP SimpleXML extension to render its sitemap, and the WordPress core documentation notes that sitemap rendering can return HTTP 501 when that requirement is unavailable.

Ask the hosting provider or server administrator to confirm the PHP version and required extensions, then check the server error logs. Do not install another sitemap plugin as the first response if the underlying PHP or server configuration is the real problem. The relevant implementation details are documented in the WordPress core sitemap notes.

Why are multiple sitemap systems active?

Multiple sitemap systems are active when WordPress core and one or more SEO or sitemap plugins each expose an endpoint, or when an old physical sitemap file remains on the server. Both /wp-sitemap.xml and /sitemap_index.xml may work, but that does not mean both are equally current or authoritative.

Choose one primary generator, disable redundant sitemap functionality where appropriate, confirm that the surviving index contains all desired URLs, update the live robots.txt reference, and remove obsolete Search Console submissions. Keep the endpoint that matches the site’s canonical and indexability configuration.

Why is the sitemap blank?

A blank sitemap can result from having no public content for that content type, marking all content as noindex, excluding a post type or taxonomy in a plugin, discouraging search engines in WordPress settings, serving a stale cache, using a non-public custom post type, or experiencing a sitemap-provider failure.

Check the sitemap index first, then inspect each child sitemap. Review SEO plugin exclusions, page visibility, custom post type settings, cache layers, and server logs. A genuinely empty content group is not necessarily a fault; a completely empty site-wide index when indexable content exists requires further investigation.

What should you do if the sitemap contains redirects or 404 URLs?

Replace redirecting and deleted URLs with their final working canonical URLs, or remove them when no replacement should be indexed. A sitemap should not be used as a historical list of every URL the site has ever published.

After correcting the source configuration, purge relevant caches and allow the sitemap to regenerate. Then reopen the child sitemap and inspect Search Console reports. A sitemap error is more serious when it affects important pages, but a warning does not automatically represent an SEO disaster if search engines can discover the affected pages through other links.

What should you do if the sitemap is blocked?

The sitemap file itself must be publicly reachable, even though the URLs inside it should be selected carefully. Check both https://yourdomain.com/robots.txt and https://yourdomain.com/wp-sitemap.xml, then inspect firewall, security-plugin, CDN, authentication, and server rules.

Do not confuse a Disallow rule with a sitemap inclusion. Robots rules control access to paths; sitemap files identify URLs for discovery. Neither mechanism overrides the other’s purpose.

Which WordPress sitemap approach should you choose?

Choose WordPress core when the site is small or straightforward and the standard sitemap contains the right canonical URLs. Choose an established SEO plugin when the site already uses that plugin or needs broader controls that core does not provide.

Site situation Recommended approach Why
Simple blog or small business site WordPress core Basic automatic sitemap generation is usually enough
Site already using Yoast SEO Use Yoast’s sitemap system Avoids duplicate generators and connects sitemap output with indexability settings
Site already using Rank Math or All in One SEO Use the active plugin’s sitemap system Keep sitemap controls within the existing SEO configuration
Large ecommerce, multilingual, news, image, or video site Review core limitations and use an appropriate SEO system or technical implementation Specialized content and exclusions may require more than core’s basic output
Persistent conflicts, custom post types, or indexing failures Technical SEO audit or experienced WordPress help The issue may involve canonicals, robots rules, status codes, plugins, caching, or server configuration—not just the sitemap

Do not buy a plugin simply to create a sitemap: WordPress core provides that basic function without a paid add-on. A broader SEO plugin becomes easier to justify when the site also needs metadata, schema, redirects, advanced exclusions, or specialized sitemap extensions.

What is the simplest correct WordPress sitemap setup?

For most site owners, the correct setup takes five steps:

  1. Open /wp-sitemap.xml on the production HTTPS domain.
  2. If an SEO plugin is the authoritative generator, use its index URL instead, commonly /sitemap_index.xml.
  3. Review the index and child files for canonical, public, indexable URLs.
  4. Confirm the sitemap reference in robots.txt.
  5. Submit the sitemap index in Google Search Console and fix errors affecting important URLs.

Keep internal links, canonical tags, page quality, HTTP status codes, and indexing directives correct. An XML sitemap is a useful discovery aid, not a substitute for a crawlable and well-structured WordPress site.

Frequently Asked Questions

Is an XML sitemap necessary for every WordPress site?

No. An XML sitemap is not essential for every small, well-linked WordPress site, but keeping the automatically generated sitemap enabled is generally reasonable. Google’s current guidance describes a small site as roughly 500 or fewer pages that the owner wants indexed when important pages are comprehensively linked internally.

What is the correct WordPress sitemap URL?

The standard WordPress core sitemap URL is https://yourdomain.com/wp-sitemap.xml for WordPress 5.5 and later. An SEO plugin may instead generate an index at https://yourdomain.com/sitemap_index.xml; check the live endpoint and robots.txt rather than assuming /sitemap.xml is correct.

Should a sitemap contain pages marked noindex?

Generally, no. A sitemap should contain canonical URLs that the site wants search engines to index, while URLs marked noindex should normally be excluded. A sitemap listing a noindex URL creates a contradictory signal and makes Search Console reports harder to interpret.

Does an XML sitemap improve Google rankings?

No. An XML sitemap can help Google discover URLs, especially on large, new, poorly linked, or frequently changing sites, but it does not guarantee crawling, indexing, rankings, or search-result inclusion.

Should you submit every child sitemap separately to Google Search Console?

Usually, no. Submit the sitemap index because the index already references the child sitemaps and can update as content changes. Submit individual child sitemaps only when targeted monitoring or troubleshooting gives you a specific reason.

The Bottom Line

Bottom line: Start by checking https://yourdomain.com/wp-sitemap.xml. If an SEO plugin controls sitemap generation, submit that plugin’s index—often /sitemap_index.xml—instead. Keep only final, canonical, public URLs in one authoritative sitemap system, reference that index in robots.txt, and submit it to Google Search Console. A sitemap helps search engines discover pages; it does not guarantee indexing or rankings.

Product prices and availability are accurate as of the date/time indicated and are subject to change. Any price and availability information displayed on Amazon at the time of purchase will apply.

Independent reader supportYour contribution helps us test, update, and keep practical guides available for everyone.Support on Ko-Fi