You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

sitemap.md 1.1KB

12345678910111213141516171819202122232425262728293031323334
  1. +++
  2. title = "Sitemap"
  3. weight = 60
  4. +++
  5. Zola will look for a `sitemap.xml` file in the `templates` directory or
  6. use the built-in one.
  7. If your site has more than 30 000 pages, it will automatically split
  8. the links into multiple sitemaps, as recommended by [Google](https://support.google.com/webmasters/answer/183668?hl=en):
  9. > All formats limit a single sitemap to 50MB (uncompressed) and 50,000 URLs.
  10. > If you have a larger file or more URLs, you will have to break your list into multiple sitemaps.
  11. > You can optionally create a sitemap index file (a file that points to a list of sitemaps) and submit
  12. > that single index file to Google.
  13. In such a case, Zola will use a template called `split_sitemap_index.xml` to render the index sitemap.
  14. The `sitemap.xml` template gets a single variable:
  15. - `entries`: all pages of the site, as a list of `SitemapEntry`
  16. A `SitemapEntry` has the following fields:
  17. ```ts
  18. permalink: String;
  19. date: String?;
  20. extra: Hashmap<String, Any>?;
  21. ```
  22. The `split_sitemap_index.xml` also gets a single variable:
  23. - `sitemaps`: a list of permalinks to the sitemaps