A sitemap date is not a valid date
In the reportInvalid sitemap lastmod
sitemap_lastmod_invalid · Issue
This appears when a <lastmod> date in your sitemap is not written in one of the two forms the check accepts, or is not a real date. Write it as YYYY-MM-DD or as a full date and time with seconds and a time zone, or leave it out when you have no reliable date.
Severity: Low. Fix it when you next work on the sitemap; the check accepts only a full date or a date and time with seconds and a zone, so a reported value is not necessarily unusable to search engines.
Why it matters
Google uses a sitemap's <lastmod> only when it is consistently and verifiably accurate. The check accepts only YYYY-MM-DD or a full date and time with seconds and a time zone; other W3C forms may still be readable, though they are reported here.
What to do
- Look at the finding: it shows the page and the lastmod value as written.
- Change the sitemap generator, usually your SEO plugin or website editor, to write dates as
2026-09-24or2026-09-24T14:30:00+01:00. - If it cannot produce a trustworthy date, leave
<lastmod>out.
What we read
We read the <lastmod> inside each <url> of your XML sitemaps, for addresses on your own site; dates in sitemap indexes and feeds are not checked, and a blank value counts as no date. A value is accepted only as YYYY-MM-DD, or as a date and time with seconds, an optional fraction and a time zone written Z or like +01:00.
Anything else is reported, including forms the W3C date format allows, such as a year alone, a year and month, or a time without seconds, and impossible values such as 29 February in a year that is not a leap year. Each page is one finding.
Example & evidence
Illustrative example — one sitemap entry, not a live audit.
https://bakery.example/sitemap.xml contains:
<url>
<loc>https://bakery.example/cakes/lemon-drizzle/</loc>
<lastmod>2026-09-24 14:30</lastmod>
</url>The date and time are separated by a space and have no seconds or time zone, so the value is reported as written.
A possible correction: <lastmod>2026-09-24T14:30:00+01:00</lastmod>, or simply <lastmod>2026-09-24</lastmod>.
Confirm & check again
Check for yourself: open your sitemap and look at the <lastmod> values: each should read like 2026-09-24 or 2026-09-24T14:30:00+01:00.
Check again: Full audit — run a new audit of the site. The finding closes when the page's date is valid, removed, or the page is no longer listed, and the page itself answers directly with 200 and a complete HTML page or a file that is not HTML, or starts with a permanent redirect within your site; every sitemap must also be read in full. A page that answers 404 or 410 cannot be confirmed.
Limits & sources
The check tests the form of the date, not whether it is true, and it does not tell whether Google uses the value. It is stricter than the W3C date format, which also allows shorter forms.
Confidence: High because the value is read and tested exactly as written.
Sources
- Google, Build and submit a sitemap — says Google uses lastmod only when it is consistently and verifiably accurate. Checked 25 September 2026.
- W3C, Date and Time Formats — defines the six W3C date forms, of which the check accepts the complete date and the forms with seconds. Checked 25 September 2026.
Editorial review: 29 September 2026