ch.at

Universal Basic Intelligence

pronounced "ch-dot-at"

sitemap.xml

sitemap.xml

A sitemap.xml file is an XML file that lists the URLs for a website along with additional metadata about each URL (when it was last updated, how often it changes, and how important it is relative to other URLs in the site). This helps search engines like Google, Bing, and Yahoo more intelligently crawl the site.

Basic Structure

The basic structure of a sitemap.xml file looks like this:

<?xml version="1.0" encoding="UTF-8"?>
<urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9">
  <url>
    <loc>http://www.example.com/</loc>
    <lastmod>2023-01-01</lastmod>
    <changefreq>monthly</changefreq>
    <priority>0.8</priority>
  </url>
</urlset>

Key Elements

  • <urlset> - The enclosing tag for the file
  • <url> - The parent tag for each URL entry
  • <loc> - The URL of the page (required)
  • <lastmod> - The date of last modification (optional)
  • <changefreq> - How frequently the page changes (optional)
  • <priority> - The priority of this URL relative to other URLs (optional)

Best Practices

    🟠 claude-3.7-sonnet