A simple page sitemap
This example lists two pages. Replace the example addresses with your own final, public URLs before publishing. The XML declaration specifies UTF-8; urlset groups entries, url represents a page and loc contains its full address.
The optional lastmod records an actual content modification date. Omit it if you cannot supply a reliable value; generating a new file does not mean every page changed.
<?xml version="1.0" encoding="UTF-8"?>
<urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9">
<url>
<loc>https://example.com/</loc>
</url>
<url>
<loc>https://example.com/about</loc>
<lastmod>2026-10-20</lastmod>
</url>
</urlset>An image sitemap
The page address stays in loc. Each image:image belongs to that page and contains the image address in image:loc. The additional namespace enables these image elements. This lists image locations; it does not embed image files.
In this generator, choose Images before crawling. Review the result: HTML image extraction may miss images loaded only by scripts.
<?xml version="1.0" encoding="UTF-8"?>
<urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9"
xmlns:image="http://www.google.com/schemas/sitemap-image/1.1">
<url>
<loc>https://example.com/gallery</loc>
<image:image>
<image:loc>https://example.com/photos/garden.jpg</image:loc>
</image:image>
</url>
</urlset>A sitemap index
An index points to sitemap files rather than individual pages. Here, sitemapindex wraps two sitemap entries. Publish those child files too. A sitemap has a protocol limit of 50,000 URLs and 50 MB uncompressed; an index can group multiple files.
This is a hand-editable learning example. sitemap.download has a separate 1,000-page-attempt crawl limit and does not automatically split files or create an index.
<?xml version="1.0" encoding="UTF-8"?>
<sitemapindex xmlns="http://www.sitemaps.org/schemas/sitemap/0.9">
<sitemap>
<loc>https://example.com/pages.xml</loc>
</sitemap>
<sitemap>
<loc>https://example.com/articles.xml</loc>
</sitemap>
</sitemapindex>Before using a sample
- Replace every example address and check the destination in a browser.
- Save as UTF-8 XML, keeping tags and namespace declarations intact.
- Escape an ampersand in a URL as
&inside XML. - Follow the publication checklist. Copying a sample does not upload or submit it.
Sources and further reading
Reviewed 2 November 2026. Platform behaviour can change; consult the linked documentation for your setup.