sitemap.xml
A `sitemap.xml` file is an XML format file that lists the pages of a website to inform search engines about the organization of your site's content. Here are some key points:
- Purpose: Helps search engines crawl your site more intelligently.
- Structure: Contains URLs and additional metadata like:
- lastmod: The last modified date of the page.
- changefreq: How often the page is likely to change.
- priority: The priority of the page relative to other pages on the site.
- Format: Must follow XML syntax. A basic structure looks like this:
<?xml version="1.0" encoding="UTF-8"?>
<urlset xmlns="http://www.sitemaps.org/schemas/sitemap-image/1.1">
<url>
<loc>http://www.example.com/</loc>
<lastmod>2023-01-01</lastmod>
<changefreq>weekly</changefreq>
<priority>1.0</priority>
</url>
<url>
<loc>http://www.example.com/about</loc>
<lastmod>2023-01-01</lastmod>
<changefreq>monthly</changefreq>
<priority>0.8</priority>
</url>
</urlset>
- Submission: Can be submitted through Google Search Console and other webmaster tools.
- Benefits: Improves indexing speed and helps with SEO.