In short. Change a page's sitemap lastmod after a significant update, retain it when only the sitemap is regenerated, and omit it when the date is unreliable.
Definition: A sitemap's
<lastmod>value records the date of the listed page's last significant update. As of October 2026, Google's sitemap construction documentation says Google uses this value when it is consistently and verifiably accurate.
Key facts
- Google's sitemap construction documentation treats updates to main content or page links as generally significant; a copyright date change is insignificant.
- The Sitemaps protocol makes
<lastmod>optional and ties its value to the linked page's modification date, independently of sitemap generation. - Google's lastmod guidance describes it as a signal for scheduling crawls of previously found URLs.
Which changes warrant a new value?
Google's lastmod guidance says to update the value when the primary text changes or page links are updated. Google's structured data introduction defines structured data as a standardized format for providing information about a page and classifying its content. The lastmod guidance includes additions or changes to that data among significant modifications.
The same guidance says an insignificant text change in a sidebar or footer can leave the value unchanged. Google's sitemap construction documentation gives the copyright date as another example. A routine footer edit therefore provides no reason by itself to refresh every page's timestamp.
What should the XML contain?
The Sitemaps protocol specifies W3C Datetime formatting and allows a date without a time, using YYYY-MM-DD. Its definition ties the date to the linked page. Rebuilding a sitemap while the page remains unchanged leaves that page's modification date unchanged.
Google's basic XML example contains a single URL and its date:
<?xml version="1.0" encoding="UTF-8"?>
<urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9">
<url>
<loc>https://www.example.com/foo.html</loc>
<lastmod>2022-06-04</lastmod>
</url>
</urlset>
The date belongs to Google's example. In an actual sitemap, it represents the listed page's last significant update. The protocol also permits a timestamp with a time and timezone offset.
How should unreliable dates be handled?
Google's lastmod guidance permits the element on all pages or only those with reliable dates. It specifically mentions homepages and category pages that aggregate other pages: some site software has difficulty determining their modification dates, and Google accepts omitting <lastmod> for them.
The same guidance says Search Console reports unsupported date formats after sitemap submission. Google's construction documentation describes verifying accuracy by comparing the value with the page's last modification and identifies the Sitemaps report as a place to see processing errors.
Related terms
- XML sitemap
- Structured data
- Does submitting a sitemap ensure indexing?
- Does Google use sitemap priority and changefreq values?
FAQ
Should I put today's date on every URL?
The Sitemaps protocol ties each date to the corresponding page's last modification. Regenerating the file alone leaves those page dates unchanged.
Can I omit lastmod when I cannot determine it reliably?
Yes. Google's lastmod guidance explicitly permits leaving it out for pages whose modification dates the site software cannot reliably determine.
Does lastmod mean the same thing in a sitemap index?
A sitemap index lists sitemap files. The Sitemaps protocol assigns its <lastmod> value to the corresponding sitemap file's modification time; page entries carry their own page dates.
Sources
- Google Search Central, "Build and submit a sitemap", updated 8 July 2026
- sitemaps.org, "Sitemaps XML format", undated
- Google Search Central, "Sitemaps ping endpoint is going away", 26 June 2023
- Google Search Central, "Introduction to structured data markup in Google Search", updated 10 December 2025
Check how a page reads to answer engines. Open the GEO score analyzer