To create a sitemap for a website, first check whether your CMS already generates one automatically. WordPress, Wix, Shopify, and current Squarespace websites commonly provide XML sitemaps. If no sitemap exists, create a UTF-8 XML or text file containing only canonical, public, indexable URLs, publish it, then submit it in Google Search Console.
A sitemap helps search engines discover important pages, especially on new, large, complex, or poorly linked websites. A sitemap is a discovery hint—not a guarantee that Google will crawl, index, or rank every listed URL.
Key takeaways
- Most modern website platforms generate a sitemap automatically, so check the CMS before creating a second sitemap.
- A sitemap should contain canonical, public, indexable URLs that the site owner wants to appear in search results.
- Google supports XML, RSS or Atom, and plain-text sitemap formats; XML is the most flexible format.
- Each sitemap can contain up to 50,000 URLs and be up to 50 MB uncompressed.
- Submitting a sitemap to Google Search Console is a discovery hint and does not guarantee crawling, indexing, or improved rankings.
What is a sitemap?
A sitemap is a file that tells search engines about important URLs on a website and can provide additional information about those URLs. The file may describe web pages, images, videos, news content, and relationships between localized versions. This guide focuses mainly on XML sitemaps for search engines.
According to Google’s sitemap documentation, sitemaps are particularly useful when a website is new, large, difficult to navigate, or contains specialized content such as video, images, or news.
XML sitemap
An XML sitemap is a machine-readable file, usually named something such as sitemap.xml or sitemap_index.xml. An XML sitemap can include absolute URLs and meaningful last-modified dates, and it can be extended for images, videos, news, and alternate-language information.
HTML sitemap
An HTML sitemap is a normal webpage containing links for human visitors. An HTML sitemap can improve navigation and add internal links on a large or complicated website, but an HTML sitemap and an XML sitemap are separate assets. An HTML sitemap does not replace an XML sitemap, and an XML sitemap is not a substitute for useful site navigation.
Sitemap index
A sitemap index is an XML file listing multiple sitemap files. A sitemap index is useful when a website exceeds the limits of one sitemap or separates content into files such as posts, products, and pages. A sitemap index lists sitemap files, not ordinary page URLs.
RSS or Atom feed and text sitemap
Google supports RSS and Atom feeds as sitemap formats, particularly for recently published or updated content. A plain-text sitemap is simpler: it contains one fully qualified URL per line. Text sitemaps are limited to URLs, whereas XML sitemaps are more versatile.
Do you need a sitemap for your website?
A sitemap is most useful for a large, new, complex, frequently changing, or media-heavy website. A sitemap may help search engines discover pages that are not easily reached through ordinary internal links.
Consider using a sitemap when your website:
- Has many pages, products, posts, or other indexable resources.
- Is new and has few external links pointing to it.
- Has important pages that are several clicks away from the home page.
- Uses complex navigation, faceted URLs, JavaScript-generated content, or frequently changing pages.
- Publishes substantial image, video, or news content.
Google describes a small website as approximately 500 or fewer pages that matter for search results, provided the pages are comprehensively linked internally and the website does not depend heavily on media or news indexing. That figure is a practical guideline, not a universal rule. A five-page brochure website with clear navigation may not need a manually maintained sitemap.
If your platform already creates a valid sitemap automatically, keeping that sitemap is usually the simplest option. Creating a second sitemap can cause confusion, duplicate maintenance, or conflicting inclusion rules.
What can a sitemap do—and what can it not do?
A sitemap can help search engines discover selected URLs and understand when important content changed. A sitemap cannot force a search engine to crawl every URL, guarantee indexing, or directly guarantee higher rankings.
| A sitemap can help with | A sitemap cannot guarantee |
|---|---|
| Discovering URLs on new or poorly linked websites | Crawling every submitted URL |
| Finding important pages on large websites | Indexing every listed page |
| Communicating meaningful last-modified dates | Higher search rankings |
| Organizing page, image, video, news, or localized sitemap data | Fixing noindex, canonical, server, access, or content-quality problems |
Google describes sitemap submission as a hint, not a guarantee. Internal links, crawlable site architecture, useful content, correct canonicalization, server availability, and indexability remain important even when a sitemap is valid.
How do you check whether your website already has a sitemap?
Before creating a sitemap for a website, look for an automatically generated file. The exact URL depends on the platform, configuration, plugins, and theme; /sitemap.xml is common but is not universal.
- Open the sitemap location documented by your platform.
- Open
https://example.com/robots.txtand look for a line beginning withSitemap:. - Review your CMS, SEO, or website settings for a sitemap control.
- Search the platform’s help center for “sitemap.”
- Check Google Search Console if a sitemap has already been submitted.
Common locations include:
| Platform or setup | Possible sitemap location or discovery method | Important qualification |
|---|---|---|
| WordPress core | https://example.com/wp-sitemap.xml |
Modern WordPress installations include native XML sitemap functionality. |
| Yoast SEO on WordPress | Often https://example.com/sitemap_index.xml |
The active plugin and site configuration determine the actual endpoint. |
| Wix | Automatically generated sitemap index | Check the SEO Setup Checklist and inspect the index. |
| Shopify | Automatically generated store sitemap | The store must be publicly accessible; password protection prevents search-engine access. |
| Current Squarespace | Automatically generated sitemap | Legacy Squarespace 5 has different behavior. |
| Custom website | A URL selected by the site owner | Generate it from the CMS, database, build process, or deployment pipeline where possible. |
How do you create a sitemap on WordPress?
WordPress users should check the native sitemap before installing a plugin. WordPress provides native XML sitemap functionality, and a basic native sitemap is often sufficient for a small website.
Open the likely native endpoint:
https://example.com/wp-sitemap.xml
If an SEO plugin controls the sitemap, use that plugin’s endpoint instead. For Yoast SEO, the current settings path is WordPress Dashboard → Yoast SEO → Settings → Site features → XML sitemaps. Yoast explains that its sitemap updates automatically as content is added or removed and excludes content that is not eligible for indexing.
Do not run WordPress core, an SEO plugin, and a standalone sitemap plugin without checking how their endpoints interact. Choose one primary sitemap generator and verify which endpoint is active. A sitemap at /sitemap.xml may be produced by WordPress core or another plugin rather than Yoast.
A plugin is useful when you need additional controls over post types, taxonomies, exclusions, or specialized SEO features. A plugin is unnecessary merely because a native WordPress sitemap already works.
How do you create a sitemap on Wix?
Wix generally generates a sitemap automatically. Wix documentation states that the sitemap index can be submitted to Google automatically after completing the SEO Setup Checklist.
- Complete or review the Wix SEO Setup Checklist.
- Open the generated sitemap index.
- Check that important pages, blog posts, products, and localized pages appear as expected.
- Do not create a duplicate manually generated sitemap unless a specific technical requirement justifies it.
Wix’s sitemap documentation also notes that Wix Stores may have additional product-related sitemap files.
How do you create a sitemap on Shopify?
Shopify automatically provides a sitemap for a store, so Shopify store owners normally configure page-level SEO and store visibility rather than hand-editing the sitemap.
Shopify’s sitemap cannot be accessed by search engines while the website is password-protected. Make the store publicly accessible before expecting search engines to use the sitemap. Verify the website in Google Search Console if you want to submit the sitemap manually.
Use Shopify’s official sitemap instructions to locate the platform-controlled file. Do not upload a second hand-maintained sitemap for ordinary Shopify content.
How do you create a sitemap on Squarespace?
Current Squarespace websites generally provide an automatically generated sitemap. Open the sitemap URL documented in Squarespace’s current sitemap guidance and check that public pages are represented.
Do not assume that current Squarespace instructions apply to every Squarespace product. Legacy Squarespace 5 documentation describes different behavior, so identify the product version before troubleshooting a missing sitemap.
How should you create a sitemap for a custom-coded website?
For a custom-coded website, generate the sitemap from the site’s database, CMS, build process, or deployment pipeline. Automated generation is preferable for a website with more than a few dozen URLs because manual maintenance becomes tedious and error-prone.
A reliable generator should:
- Include only canonical URLs intended for search.
- Update when pages are added, removed, or meaningfully changed.
- Exclude private, redirected, duplicate, error, search-result, and
noindexURLs. - Split large sites into multiple sitemap files.
- Output UTF-8 encoded files.
- Use fully qualified absolute URLs.
A manual file is reasonable for a tiny static website whose URLs rarely change. An online generator can be useful for a one-time diagnostic, but a generated download will become stale unless the website has a process for regenerating and publishing it.
How do you create an XML sitemap manually?
For a very small static website, create a UTF-8 file named something such as sitemap.xml and list each preferred page inside a <url> element.
<?xml version="1.0" encoding="UTF-8"?>
<urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9">
<url>
<loc>https://www.example.com/</loc>
<lastmod>2026-08-10</lastmod>
</url>
<url>
<loc>https://www.example.com/about/</loc>
<lastmod>2026-08-05</lastmod>
</url>
<url>
<loc>https://www.example.com/contact/</loc>
</url>
</urlset>
The dates in the example are illustrative. Replace them with dates that accurately represent meaningful updates, or omit <lastmod> when no trustworthy date exists.
What do the XML sitemap elements mean?
| Element | Purpose | Requirement |
|---|---|---|
urlset |
Root element containing the sitemap entries | Required |
url |
One page entry | Required for each listed URL |
loc |
The page’s fully qualified absolute URL | Required |
lastmod |
Date of a meaningful page update | Optional |
Use lastmod when the main content, structured data, or important links changed. Do not update lastmod merely because an automated process touched the file, a copyright year changed, or a page was republished without meaningful changes.
Do not add invented changefreq or priority values as SEO controls. The Sitemap protocol states that priority is unlikely to influence search-result position, and inaccurate metadata is less useful than a clean list of correct URLs.
Which URLs belong in a sitemap?
Include URLs that are canonical, publicly accessible, intended to appear in search results, and capable of returning a successful indexable response.
Include these URLs
- The preferred HTTPS version of each important page.
- Canonical product, service, category, article, and location pages intended for search.
- Public pages that return a successful response and are not marked
noindex. - Meaningful localized versions when the website has a consistent alternate-language implementation.
Exclude these URLs
- Redirects and URLs that resolve to another preferred destination.
- 404 pages, soft-404 pages, and error pages.
- Pages blocked by authentication or access controls.
- Pages marked
noindex. - Duplicate parameter variations and thin filter combinations.
- Internal search-result pages.
- Login, cart, checkout, account, and administrative pages.
- Staging, development, preview, and test URLs.
- Alternate URLs that declare another page as canonical.
A URL can be technically crawlable but still be a poor sitemap candidate if the site owner does not want that URL indexed. A sitemap should represent the site’s preferred search URLs, not every URL the website can technically generate.
What are the sitemap size and format limits?
One sitemap can contain up to 50,000 URLs and can be up to 50 MB uncompressed. Larger websites must split URLs across multiple sitemap files and reference those files from a sitemap index.
Sitemap files must use UTF-8 encoding, and listed URLs must be fully qualified absolute URLs. The Google sitemap creation documentation covers the current size, location, encoding, and URL requirements.
<?xml version="1.0" encoding="UTF-8"?>
<sitemapindex xmlns="http://www.sitemaps.org/schemas/sitemap/0.9">
<sitemap>
<loc>https://www.example.com/pages-sitemap.xml</loc>
<lastmod>2026-08-10</lastmod>
</sitemap>
<sitemap>
<loc>https://www.example.com/posts-sitemap.xml</loc>
<lastmod>2026-08-10</lastmod>
</sitemap>
</sitemapindex>
A sitemap index references sitemap files, not ordinary pages. A CMS or server-side generator should handle splitting automatically for a large or frequently changing website.
How do you upload and publish a sitemap?
Upload a manually created sitemap to a publicly accessible web location, preferably at the site root.
- Save the file as
.xmlor.txtusing UTF-8 encoding. - Upload the file to the web server or deploy it through the website’s build system.
- Use a root-level URL such as
https://www.example.com/sitemap.xmlwhere practical. - Open the exact URL in a private browser window.
- Confirm that the response is the sitemap, not an HTML error page, login screen, or redirect chain.
- Confirm that the file is accessible without authentication.
- Add the sitemap location to
robots.txt.
Your robots.txt file can include:
User-agent: *
Disallow:
Sitemap: https://www.example.com/sitemap.xml
A sitemap declaration in robots.txt helps search engines discover the file. Multiple sitemap declarations are permitted. Publishing the sitemap at the site root is a safe general choice because sitemap location can affect directory scope in some submission contexts.
How do you submit a sitemap to Google Search Console?
Submit a sitemap in Google Search Console by selecting the correct property, opening Sitemaps under the indexing section, entering the sitemap path or URL, and selecting Submit.
- Open Google Search Console.
- Select the correct domain or URL-prefix property.
- Open Sitemaps in the indexing section.
- Enter the sitemap path or complete sitemap URL.
- Select Submit.
- Review the submission status and discovered URL count.
- Return to the report after Google processes the file.
Google Search Console’s sitemap help page explains that the report can show when Google accessed a submitted sitemap and whether processing errors occurred. Only sitemaps submitted through the report or Search Console API appear in that report; Google can still discover a sitemap through robots.txt or other methods.
Submitting a sitemap does not instantly index pages. For one urgent URL, URL Inspection can be used separately to request a recrawl, but a recrawl request does not replace fixing noindex directives, canonical conflicts, access problems, weak internal linking, or broader site-quality issues. See Google’s recrawl guidance for the distinction.
How do you submit a sitemap to Bing Webmaster Tools?
Verify the website in Bing Webmaster Tools, then add and manage the XML sitemap or sitemap index using the standard Sitemap protocol.
Bing’s Webmaster Tools checklist documents sitemap support and the verification-first workflow. Submitting the same valid sitemap to Google and Bing is generally simpler than maintaining separate files.
How do you validate and troubleshoot a sitemap?
Start with the sitemap URL itself, then compare every listed URL with the page’s HTTP response, canonical tag, indexability directives, and intended search visibility.
Basic validation checklist
- Does the sitemap load without a login?
- Does the URL return HTTP 200 rather than a redirect or error?
- Is the response XML or plain text rather than a normal webpage?
- Are all URLs absolute and fully qualified?
- Do all URLs use the preferred protocol and hostname?
- Does the XML contain malformed characters or invalid syntax?
- Are there duplicate URLs?
- Do listed pages return successful, indexable responses?
- Do listed pages match their canonical URLs?
- Is the file within the URL and uncompressed-size limits?
- Is the
robots.txtdeclaration spelled correctly? - Does Search Console accept the sitemap?
What does “Couldn’t fetch” mean?
“Couldn’t fetch” usually means Google could not retrieve or process the sitemap at the submitted URL. Possible causes include an incorrect URL, temporary server outage, DNS or SSL failure, firewall or bot protection, authentication, a 404, 403, or 5xx response, an unexpected redirect, invalid XML, or a server content-configuration problem.
- Open the exact submitted URL in an incognito browser window.
- Check the HTTP status and final destination.
- Review server logs, DNS, SSL, and firewall rules.
- Remove authentication or password protection if search engines should access the file.
- Correct malformed XML or server output.
- Resubmit the sitemap after confirming that it is publicly accessible.
How do you fix “Submitted URLs marked noindex”?
Remove URLs marked noindex from the sitemap, or remove the noindex directive if the pages are genuinely intended for indexing. A sitemap should not recommend URLs that the website explicitly tells search engines not to index.
How do you fix “Submitted URL blocked by robots.txt”?
Decide whether the URL should appear in search results. If the URL should be indexed, remove the inappropriate robots.txt block and verify that the page is otherwise indexable. If the URL should not be indexed, remove it from the sitemap as well.
Why can a sitemap be valid while a URL is not indexed?
A valid sitemap, crawlability, canonicalization, and indexing are separate systems. Sitemap inclusion cannot override a noindex directive, a canonical pointing elsewhere, inaccessible content, poor-quality signals, server failures, or a search engine’s decision not to index a page.
How do you fix duplicate sitemap generators?
Identify every system producing a sitemap, such as WordPress core, an SEO plugin, and a standalone sitemap plugin. Select one primary generator, confirm its endpoint, and submit that endpoint. Remove or disable redundant systems only after checking that the active sitemap remains available.
How do you fix stale last-modified dates?
Set lastmod only when the page has had a meaningful content or structural update. Do not change the date for routine automated deployments, copyright-year changes, or superficial republishing.
Why is a sitemap empty?
An empty sitemap can mean that all content is set to noindex, the site is private, the generator excludes the selected content type, no public indexable pages have been published, or a plugin, rewrite rule, or server configuration is malfunctioning.
Which sitemap approach should you use?
| Website type | Best default | Why |
|---|---|---|
| Five-page static site | No sitemap or a small manual XML sitemap | Clear internal navigation may already make every page easy to discover. |
| Small WordPress site | WordPress native sitemap | Automatic generation avoids manual maintenance. |
| WordPress site needing SEO controls | One established SEO plugin, such as Yoast SEO | Additional controls can help with content types and exclusions, but a plugin is not required for basic sitemap generation. |
| Wix, Shopify, or Squarespace site | Built-in platform sitemap | The hosted platform manages generation and updates. |
| Large ecommerce or publishing site | Automated generation plus a sitemap index | Frequent changes and sitemap limits make manual editing unreliable. |
| Custom-coded website | Database, CMS, build, or deployment integration | The sitemap stays synchronized with canonical, public content. |
What are specialized sitemap options?
Specialized sitemap extensions are useful when discovery of a particular content type is a meaningful objective. Google recognizes formats and extensions for images, videos, news, and alternate-language information.
- Image sitemap: Consider it when image discovery is an important search objective.
- Video sitemap: Consider it when the website publishes substantial video content and follows the current requirements.
- News sitemap: Consider it for eligible news content rather than for every ordinary blog.
- Alternate-language data: XML sitemaps can carry localized-version information, but simply listing translated URLs does not complete a consistent hreflang implementation.
Do not create specialized sitemap files merely because a website contains an image or video. Use the extension when it adds useful, accurate discovery information.
Should you use an XML sitemap, HTML sitemap, or RSS feed?
Choose the format according to the discovery and maintenance problem: XML is the best general-purpose format, HTML supports human navigation, and RSS or Atom is useful for recent content.
| Format | Best use | Main limitation |
|---|---|---|
| XML | Comprehensive URL lists and metadata or specialized extensions | Requires valid XML structure and accurate maintenance. |
| Plain text | A simple list of page URLs | Supports URLs only. |
| RSS or Atom | Recently published or updated content | Usually does not provide a comprehensive list of all important URLs. |
| HTML | Visitor navigation and internal linking | Designed for people, not a replacement for an XML sitemap. |
Which tools are actually necessary?
Most website owners do not need to buy a sitemap product. WordPress core, Wix, Shopify, and current Squarespace websites commonly generate sitemaps without a separate purchase.
WordPress users should start with the native sitemap. Yoast SEO is an optional choice when a WordPress site needs sitemap controls alongside broader on-page SEO features. A tiny site whose native sitemap already works does not need Yoast solely to obtain a sitemap.
A technical SEO crawler can audit whether sitemap URLs return the expected status codes, match canonical URLs, avoid redirects, and are not blocked or marked noindex. A crawler is usually unnecessary for a five-page site and does not replace automatic sitemap generation on a changing website.
Frequently Asked Questions
Does every website need a sitemap?
No. A small website with approximately 500 or fewer important pages may not need a sitemap when every important page is comprehensively linked internally and the site does not depend heavily on media or news indexing. A valid automatically generated sitemap is still usually useful and harmless.
Is /sitemap.xml always the correct sitemap URL?
No. The correct sitemap URL depends on the platform and configuration. WordPress core commonly uses /wp-sitemap.xml, Yoast SEO commonly uses /sitemap_index.xml, and hosted platforms may provide a platform-controlled sitemap index.
Does a sitemap improve Google rankings?
A sitemap can help Google discover important URLs, but submitting a sitemap does not guarantee crawling, indexing, or higher rankings. A sitemap also cannot replace internal linking, useful content, correct canonicalization, or fixing noindex and access problems.
Should pages marked noindex be included in a sitemap?
No. Remove noindex URLs from the sitemap unless the noindex directive is being removed because the pages are intended for search. A sitemap should contain preferred URLs that are publicly accessible and indexable.
Can you submit multiple sitemaps?
Yes. A website can use multiple sitemap files and a sitemap index can list them. Each sitemap must remain within the limit of 50,000 URLs and 50 MB uncompressed, and the sitemap index should reference sitemap files rather than ordinary page URLs.
The Bottom Line
Creating a sitemap for a website usually starts with finding the file your platform already generates—not building one from scratch. Use one reliable generator, include only canonical public indexable URLs, publish the file where search engines can access it, declare it in robots.txt, and submit it through Search Console. Treat the sitemap as a discovery aid while solving internal-linking, crawlability, canonical, and content-quality issues separately.
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.