On this page
What this issue is
An XML sitemap is a file that lists the URLs you want search engines to crawl. Each entry can include a <lastmod> tag: the date the page was last meaningfully changed. Two things go wrong. Either the tag is missing on every URL, or it is present but identical everywhere, usually because the generator stamps each URL with the date or time the sitemap was built.
<!-- Good: real date per URL -->
<url>
<loc>https://example.com/pricing/</loc>
<lastmod>2025-03-14</lastmod>
</url>
<url>
<loc>https://example.com/blog/how-to-choose/</loc>
<lastmod>2025-05-02T09:30:00+00:00</lastmod>
</url>
<!-- Problem: same value on every URL -->
<url>
<loc>https://example.com/pricing/</loc>
<lastmod>2025-06-20T04:00:00+00:00</lastmod>
</url>
<url>
<loc>https://example.com/blog/how-to-choose/</loc>
<lastmod>2025-06-20T04:00:00+00:00</lastmod>
</url>Why it costs you leads or sales
The impact is low and indirect. Crawlers have limited time for your site. A trustworthy lastmod helps them spot which pages changed, so updated pricing, offers or landing pages get recrawled sooner. If the date is the same everywhere, crawlers cannot tell what is new, and they may fall back on their own guesses.
- You edit a pageNew price or offer goes live
- Sitemap lastmodMissing or same date on every URL
- Crawler prioritisesCannot tell what changed
- Search shows updateSlower to appear
A changed page is only recrawled quickly if the sitemap signal can be trusted.
How to check if your site has it
Open your sitemap
Visit /sitemap.xml, /sitemap_index.xml (Yoast, Rank Math) or /wp-sitemap.xml (WordPress core). If it is an index, open one child sitemap.
View the source
Right-click and choose View page source, or use curl, so you see the raw XML.
Look for lastmod on each URL
Check that every
<url>has a<lastmod>.Compare the dates
If all dates match to the minute, or equal today's date, they are probably generated at build time.
Spot-check against reality
Pick three pages you know you edited long ago. Their lastmod should be old, not recent.
curl -s https://example.com/sitemap.xml | grep -o '<lastmod>[^<]*' | sort | uniq -c | sort -rn | headIf one value accounts for nearly every line, you have the problem. If there are no lines at all, lastmod is missing. You can also crawl your sitemap with a tool such as Screaming Frog, which lists the lastmod column, or look at the Sitemaps report in Google Search Console for read errors.
How to fix it
The goal is simple: each URL's lastmod equals the last time its main content really changed. Not the build time, not the time a footer or sidebar changed, and not the current date on every request.
Use the built-in or SEO plugin sitemap
WordPress core (5.5+) sitemaps at /wp-sitemap.xml include lastmod for posts and pages from the modified date. Yoast SEO and Rank Math also output lastmod from the post modified date.
Find what bumps the modified date
Bulk edits, plugins that touch every post, or a scheduled job that re-saves content can reset the modified date on all pages. Disable or limit them.
Avoid two sitemaps
Make sure only one plugin generates the sitemap, so you are not checking the wrong file.
Know the limits
Shopify generates /sitemap.xml automatically and you cannot edit it directly. Check whether lastmod appears for your products, pages and blogs.
Keep updates real
Avoid bulk product re-saves or import jobs that touch every item, as they can change updated dates sitewide.
Use the auto-generated sitemap
In Site settings, open SEO and turn on Auto-generate sitemap. Webflow sets lastmod from publishing activity.
Publish only what changed where possible
Republishing the whole site can update dates broadly. Check the result after a publish.
Rely on the automatic sitemap
Wix creates and updates /sitemap.xml for you and it is not editable. If lastmod looks wrong, check it against pages you edited and contact Wix support if it does not match.
Use the automatic sitemap
Squarespace generates /sitemap.xml and it cannot be edited. Check what it outputs for lastmod and treat it as a platform limit if values look uniform.
Store a real modified date
Keep an updated_at column (or file modified time) per page and write it into lastmod. Update it only when content changes.
Use W3C datetime format
Use YYYY-MM-DD or a full timestamp such as 2025-05-02T09:30:00+00:00.
Do not use the current time
Never output now() for every URL at request or build time.
<?php
// $pages comes from your database, with 'url' and 'updated_at' columns
header('Content-Type: application/xml; charset=utf-8');
echo '<?xml version="1.0" encoding="UTF-8"?>';
echo '<urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9">';
foreach ($pages as $p) {
$date = date('c', strtotime($p['updated_at']));
echo '<url><loc>' . htmlspecialchars($p['url']) . '</loc>';
echo '<lastmod>' . $date . '</lastmod></url>';
}
echo '</urlset>';How to confirm it's fixed
- Re-run the curl command: you see many different lastmod values, not one.
- Every URL in the sitemap has a lastmod.
- Dates match the real last edit on three spot-checked pages.
- Dates are in valid format (YYYY-MM-DD or full timestamp with timezone).
- Editing one page changes only that page's lastmod.
- Search Console shows the sitemap as Success with no errors.
Before
- Every URL shows the build date
- Old pages look freshly updated
- Crawlers learn to ignore the tag
After
- Each URL shows its real last change
- Only edited pages move
- The signal stays trustworthy
How to prevent it happening again
- Choose one sitemap generator and disable the others.
- After plugin, theme or migration changes, re-run the distinct lastmod count.
- Be careful with bulk edits and re-saves; they can reset modified dates.
- Add a sitemap check to your release checklist.
- Review the sitemap after any CMS upgrade or move to a new platform.
How FunnelGuard handles this
FunnelGuard does not check sitemap lastmod values today. It is a possible future check. FunnelGuard is a synthetic monitoring service: a robot visitor runs your real customer journeys, such as lead forms, checkouts and booking buttons, and checks each step, the tracking hits sent to ad and analytics platforms, and whether test leads arrive. That covers what happens after a visitor lands, not how your sitemap is built.
Questions people ask
Why is my sitemap lastmod the same on every URL?
Your generator is probably stamping each URL with the time the sitemap was built, or a plugin or import job has re-saved every page and reset the modified date. Check how your CMS or plugin sets lastmod and look for bulk updates.
Is lastmod required in an XML sitemap?
No. Only <loc> is required for each URL. But an accurate lastmod helps search engines decide which pages to recrawl, so it is worth including when you can keep it correct.
Does Google use sitemap lastmod?
Google has said it uses lastmod when it is consistently and verifiably accurate. It ignores <changefreq> and <priority>. If your dates are wrong or identical, Google may disregard the field.
What format should lastmod use?
Use W3C datetime: either a date like 2025-05-02, or a full timestamp such as 2025-05-02T09:30:00+00:00. Include the timezone when you give a time.
Can wrong lastmod values hurt my rankings?
There is no known penalty, but inaccurate dates make the signal useless, so updated pages may be recrawled more slowly. The impact is usually small and indirect.
How do I fix lastmod in WordPress?
Use one sitemap source (core, Yoast or Rank Math), which outputs the post modified date. Then stop plugins or bulk edits from re-saving every post, because that resets the dates.
Should I update lastmod every time I change a page?
Only for meaningful changes to the main content, structured data or links. Small tweaks like a copyright year or a sidebar widget should not change it.
Does FunnelGuard check my sitemap lastmod?
No, not yet. It is a possible future check. For now, use curl, a crawler such as Screaming Frog or Search Console to review it.
Related issues
- SEO-104Sitemap stale: new pages missingFix guide
- SEO-105Sitemap lists 404, redirect, noindex or canonicalised URLsFix guide
- SEO-103Sitemap XML invalid or wrong namespaceFix guide
- SEO-113Plugin generates duplicate sitemaps (Yoast plus Rank Math)Fix guide
- SEO-110Money pages missing from the sitemapFix guide
- SEO-099No XML sitemapFix guide