Sitemap
The /sitemap.xml URL provides the BigCommerce sitemap index for your storefront’s default channel, the channel set by BIGCOMMERCE_CHANNEL_ID.
Its entries use the channel’s permanent URLs, the same ones used for GraphQL Storefront API requests, and each one returns the relevant sitemap for that channel.
For an example, see the Catalyst demo storefront’s sitemap.
How Catalyst serves the sitemap
Catalyst acts as an intermediary when handling requests to /sitemap.xml. When a request is made, Catalyst fetches the sitemap index from BigCommerce by making a request to the canonical URL of the default channel. Catalyst then returns the XML response, so the sitemap appears to be served directly from Catalyst. The route runs outside the proxy chain, so it has no request locale: on a storefront that maps locales to separate channels in channels.config.ts, the sitemap still comes from the default channel only.
You can find the implementation for the route in the Catalyst repository. In your project, it’s at app/sitemap.xml/route.ts.
Why the sitemap index uses the permanent URL
The sitemap index at /sitemap.xml is served from your storefront domain, but the <loc> entries inside it point to the channel’s BigCommerce permanent URL, such as store-{store_hash}-{channel_id}.mybigcommerce.com. This is expected and does not affect SEO.
A sitemap index does not list page URLs. It lists the locations of other sitemaps, and the page URLs live one layer in, inside those:
Crawlers read and index the page URLs in the third row, which are on your own domain when the channel has a custom domain configured. The permanent URL in the index is only a pointer to the next file, and sitemaps are read by crawlers rather than shoppers.
Seeing mybigcommerce.com in the sitemap index does not mean your pages are indexed on that domain. To confirm, open one of the <loc> URLs from the index and check the page URLs inside it.
Flexibility and limitations
Sitemaps don’t need to be on the same domain as the website they represent.
Catalyst includes a route that permanently redirects requests for the legacy Stencil sitemap /xmlsitemap.php to /sitemap.xml.
The sitemap covers BigCommerce-managed URLs, such as products, brands, and categories. If your storefront also has pages from third-party systems, such as Makeswift pages, submit additional sitemaps to cover those URLs.