Understanding XML Sitemaps
An XML sitemap is a file that lists all important pages of your website.
Key Purpose
- Help search engines discover your content
- Provide metadata about your pages
- Improve crawl efficiency
- Indicate page importance
Sitemap Structure
Basic Structure
<?xml version="1.0" encoding="UTF-8"?>
<urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9">
<url>
<loc>https://example.com/</loc>
<lastmod>2024-01-01</lastmod>
<changefreq>weekly</changefreq>
<priority>1.0</priority>
</url>
</urlset>Required Elements
urlset
The root element that contains all URL entries.
url
Each URL entry in the sitemap.
loc
The full URL of the page. This is the only required element for each URL.
Optional Elements
lastmod
The date the page was last modified. Format: YYYY-MM-DD.
changefreq
How frequently the page is likely to change. Values: always, hourly, daily, weekly, monthly, yearly, never.
priority
The priority of this URL relative to other URLs. Range: 0.0 to 1.0.
Change Frequency
Guidelines
- always: Use for pages that change on every access (rare)
- hourly: For frequently updated content like news
- daily: For blogs or regularly updated pages
- weekly: For pages updated weekly
- monthly: For static pages with monthly updates
- yearly: For pages that rarely change
- never: For archived content that never changes
Best Practice
Be realistic. Overestimating change frequency can waste crawl budget.
Priority
Priority Values
- 1.0: Most important pages (homepage, key landing pages)
- 0.8: Important category pages
- 0.5: Standard content pages
- 0.3: Less important pages
- 0.1: Least important pages
Relative Importance
Priority is relative within your own site, not across different websites.
Sitemap Size Limits
URL Limit
Sitemaps can contain up to 50,000 URLs.
File Size
Sitemaps must be no larger than 50MB uncompressed.
Multiple Sitemaps
For sites with more than 50,000 URLs, use a sitemap index file to reference multiple sitemaps.
The Sitemap Generator tool simplifies the process of creating valid XML sitemaps for your website. Whether you're managing a small blog or a large e-commerce site, having a properly structured sitemap is essential for SEO. Start using the generator today to ensure your sitemaps are always valid and up to date.