Skip to content
Climb Google Maps: Google Business Profile optimization.

Technical SEOGuide

Sitemap Could Not Be Read in Search Console: What Causes It, and a Script That Checks Your Sitemap the Way Google Reads It

"Sitemap could not be read" means Google never got a usable file: a robots.txt block, a wrong address, a server error, a broken XML file, or low crawl demand. Here is how to tell which, from Google's own help pages, plus a free script we ran on 14 real sitemaps.

A hand holding a magnifying glass over an old paper map marked with pins

Key takeaways

  • "Sitemap could not be read" in Google Search Console means the fetch failed: Google lists a robots.txt block, a manual action, a wrong URL (404), a server error and low crawl demand as the causes.
  • Google's help page says to confirm the cause with a live URL Inspection test of the sitemap URL itself, looking for Crawl allowed "Yes" and Page fetch "Successful".
  • If a sitemap keeps failing, Google retries for a few days and then stops, so fix the cause and resubmit it in the Sitemaps report.
  • A single sitemap is limited to 50,000 URLs and 50 MB uncompressed, must be UTF-8, and needs absolute URLs with characters like & escaped.
  • On Nov. 16, 2026, our free Node.js checker found no blocking errors in 14 sitemaps from sites including WordPress.org, GOV.UK, IKEA and ABC Australia, so a failing sitemap usually points to a cause on your own site.

"Sitemap could not be read" in Google Search Console means Google tried to download your sitemap and didn't get a file it could use. On the main Sitemaps page it shows as the status "Couldn't fetch". Google's help page lists five causes: robots.txt blocks the sitemap, the site has a manual action, the address is wrong (a 404), the server returned some other error, or there is low crawl demand for the sitemap.

Most of these you can confirm in a few minutes. Below are the causes from Google's Sitemaps report help page and its sitemap documentation as they read on November 16, 2026, how to check each one, and a free script we wrote that runs the same checks from your computer. We ran it on 14 real sitemaps; the results are at the end. None of this varies by country: the same report and rules apply to every Search Console property.

What does "Sitemap could not be read" mean?

It is a fetch failure, not a problem with the pages in the sitemap. Google's help page separates two cases on a sitemap's details page:

  • "Sitemap could not be read": the fetch failed, so Google has nothing from this attempt.
  • "Sitemap can be read, but has errors": Google got the file and read what it could. Any URLs it could parse "will be queued for crawling," so this one is less urgent.

Two details from the same page matter before you panic. Google remembers what it read from a sitemap in the past, so a later failure doesn't make it "forget" those URLs. And if fetches keep failing, Google "will retry for a few days, and then stop," so you have to fix the cause and resubmit the sitemap with a new request.

How to find the real cause in Search Console

Google's own debugging steps, in order:

  1. In Sitemaps, click the failing sitemap to open its details page, then click the error name to expand the details.
  2. Copy the sitemap URL from that page and paste it into the URL Inspection tool at the top of Search Console.
  3. Run the live test, then expand Page availability.
  4. You want Crawl allowed? = "Yes" and Page fetch = "Successful". Whatever isn't, is your cause.

Inspecting the sitemap URL itself, not one of your pages, is the step most people skip.

The causes, and how to fix each

Blocked by robots.txt. "Google respects robots.txt when fetching sitemaps," the help page says. A rule like Disallow: /wp- or Disallow: /*.xml can catch a sitemap by accident. Remove or narrow the rule.

A manual action. Google doesn't read sitemaps while a site has an unresolved manual action. Check the Manual actions report in Search Console.

The wrong address (HTTP 404). Open the exact URL you submitted in a browser. Common slips: http instead of https, www against a non-www property, or a plugin that moved the sitemap. WordPress's built-in sitemap is /wp-sitemap.xml, while SEO plugins usually serve their own (Yoast uses /sitemap_index.xml, as yoast.com's own robots.txt shows). Submit the one your site actually serves.

A server error. Any other HTTP failure, such as a timeout or a firewall that blocks Google, shows as "General HTTP error". Google says some of these are temporary, so wait and see whether later attempts fail too. If they keep failing, check your security plugin or CDN bot rules.

Low crawl demand. Google lists this as a cause, and ties crawl demand to the quality of the site's content. It is the only cause you can't fix in a settings screen.

What makes a sitemap "has errors" instead

If Google fetched the file but couldn't fully read it, these are the usual problems on Google's list:

  • Parsing error, often an unescaped & in a URL. In XML it must be written &.
  • Invalid date: lastmod must be W3C Datetime, such as 2026-11-16 or 2026-11-16T08:00:00-05:00. If you give a time, you must give a time zone.
  • Incorrect namespace or Unsupported format: the root element must say xmlns="http://www.sitemaps.org/schemas/sitemap/0.9", with straight quotes.
  • Too many URLs or file size: one sitemap is limited to 50,000 URLs and 50 MB uncompressed. Split it and list the parts in a sitemap index.
  • Empty sitemap, relative URLs (/page instead of https://example.com/page) and URL not allowed (URLs on another host or protocol).

On that last one, Google's documentation adds a detail: "unless you submit your sitemap through Search Console, a sitemap affects only descendants of the parent directory." So a sitemap at /sitemaps/news.xml listing pages at /world/... works when it is submitted in Search Console, and only then.

A free script that checks your sitemap

We wrote a short Node.js script (version 18 or newer, no packages) that runs the checks above from outside: it reads your robots.txt the way Google's rules work for Googlebot, follows redirects, flags any status other than 200, uncompresses .gz files, then checks the XML root and namespace, URL count, file size, unescaped &, relative URLs, lastmod format and URLs outside the sitemap's host or folder. It sends a Googlebot user agent, so a firewall that blocks fake Googlebots may block it too; if that happens, the live URL Inspection test is the one that counts.

Save it as sitemap-check.mjs and run node sitemap-check.mjs https://example.com/sitemap.xml. It checks the file you give it, not every sitemap an index lists, so run it again on any child sitemap that fails in Search Console.

// sitemap-check.mjs: checks a sitemap URL for the problems behind
// Search Console's "Couldn't fetch" and "Sitemap could not be read".
// Usage: node sitemap-check.mjs https://example.com/sitemap.xml
// Node 18+, no packages. Checks only the file you give it (not the
// sitemaps an index lists) and only the first few thousand URLs in detail.
import { gunzipSync } from 'node:zlib';
 
const NS = 'http://www.sitemaps.org/schemas/sitemap/0.9';
const W3C = /^\d{4}(-\d{2}(-\d{2}(T\d{2}:\d{2}(:\d{2}(\.\d+)?)?(Z|[+-]\d{2}:\d{2}))?)?)?$/;
const UA = 'Mozilla/5.0 (compatible; Googlebot/2.1; +http://www.google.com/bot.html)';
 
async function robotsAllows(url) {
  const u = new URL(url);
  const res = await fetch(`${u.origin}/robots.txt`, { headers: { 'user-agent': UA } }).catch(() => null);
  if (!res || !res.ok) return { ok: true, note: `robots.txt ${res ? res.status : 'unreachable'}` };
  // Simple reading: rules in groups for "*" or "googlebot"; longest match wins, Allow wins ties.
  let groups = [], cur = null, lastWasUA = false;
  for (const raw of (await res.text()).split(/\r?\n/)) {
    const line = raw.replace(/#.*/, '').trim();
    const m = line.match(/^([a-z-]+)\s*:\s*(.*)$/i);
    if (!m) continue;
    const [, k, v] = m;
    if (k.toLowerCase() === 'user-agent') {
      if (!lastWasUA) groups.push((cur = { agents: [], rules: [] }));
      cur.agents.push(v.toLowerCase()); lastWasUA = true;
    } else { lastWasUA = false; if (cur && /^(allow|disallow)$/i.test(k)) cur.rules.push([k.toLowerCase(), v]); }
  }
  const g = groups.filter((x) => x.agents.includes('googlebot'));
  const rules = (g.length ? g : groups.filter((x) => x.agents.includes('*'))).flatMap((x) => x.rules);
  const path = u.pathname + u.search;
  let best = null;
  for (const [type, pat] of rules) {
    if (!pat) continue;
    const re = new RegExp('^' + pat.replace(/[.+?^${}()|[\]\\]/g, '\\$&').replace(/\*/g, '.*').replace(/\\\$$/, '$'));
    if (re.test(path) && (!best || pat.length > best[1].length || (pat.length === best[1].length && type === 'allow'))) best = [type, pat];
  }
  return best && best[0] === 'disallow' ? { ok: false, note: `blocked by "Disallow: ${best[1]}"` } : { ok: true, note: 'allowed' };
}
 
export async function check(url) {
  const out = { url, problems: [], warnings: [], notes: [] };
  const bad = (s) => out.problems.push(s), warn = (s) => out.warnings.push(s), note = (s) => out.notes.push(s);
  const robots = await robotsAllows(url);
  if (!robots.ok) bad(`robots.txt: ${robots.note}`);
 
  let res, hops = 0, at = url;
  for (;;) {
    res = await fetch(at, { redirect: 'manual', headers: { 'user-agent': UA } }).catch((e) => ({ error: e }));
    if (res.error) { bad(`fetch failed: ${res.error.cause?.code || res.error.message}`); return out; }
    if (res.status >= 300 && res.status < 400 && res.headers.get('location')) {
      at = new URL(res.headers.get('location'), at).href; hops++;
      if (hops > 5) { bad('more than 5 redirects'); return out; }
      continue;
    }
    break;
  }
  if (hops) note(`${hops} redirect(s) to ${at}`);
  out.status = res.status;
  if (res.status !== 200) { bad(`HTTP ${res.status}`); return out; }
  out.type = res.headers.get('content-type') || '(none)';
  let buf = Buffer.from(await res.arrayBuffer());
  if (buf[0] === 0x1f && buf[1] === 0x8b) {
    try { buf = gunzipSync(buf); note('gzip file, uncompressed fine'); } catch { bad('compression error: gzip file does not uncompress'); return out; }
  }
  out.mb = +(buf.length / 1048576).toFixed(2);
  if (buf.length > 50 * 1048576) bad('larger than 50 MB uncompressed');
  const xml = buf.toString('utf8');
  if (/^\s+</.test(xml)) warn('leading whitespace before the XML declaration (Google still reads it)');
  if (/^\s*<!doctype html|^\s*<html/i.test(xml)) { bad('this is an HTML page, not XML'); return out; }
  const root = xml.match(/<(urlset|sitemapindex)\b([^>]*)>/);
  if (!root) { bad('no <urlset> or <sitemapindex> root element'); return out; }
  out.kind = root[1];
  if (!new RegExp(`xmlns\\s*=\\s*["']${NS.replace(/\./g, '\\.')}["']`).test(root[2])) bad(`root element lacks xmlns="${NS}"`);
  if (/[“”]/.test(root[2])) bad('curly quotes in the root element');
 
  const locs = [...xml.matchAll(/<loc>\s*([\s\S]*?)\s*<\/loc>/g)].map((m) => m[1]);
  const lastmods = [...xml.matchAll(/<lastmod>\s*([\s\S]*?)\s*<\/lastmod>/g)].map((m) => m[1]);
  out.entries = locs.length;
  if (!locs.length) bad('empty: no <loc> entries');
  if (locs.length > 50000) bad(`${locs.length} entries (limit is 50,000)`);
  const base = new URL(at), dir = base.pathname.replace(/[^/]*$/, '');
  let offHost = 0, aboveDir = 0, relative = 0, unescaped = 0, badDate = 0;
  for (const raw of locs.slice(0, 5000)) {
    if (/&(?!amp;|lt;|gt;|quot;|apos;|#\d+;|#x[0-9a-f]+;)/i.test(raw)) unescaped++;
    let u; try { u = new URL(raw.replace(/&amp;/g, '&')); } catch { relative++; continue; }
    if (u.origin !== base.origin) offHost++;
    else if (!u.pathname.startsWith(dir)) aboveDir++;
  }
  for (const d of lastmods.slice(0, 5000)) if (!W3C.test(d)) badDate++;
  if (unescaped) bad(`${unescaped} URL(s) with an unescaped "&" (parsing error)`);
  if (relative) bad(`${relative} relative or invalid URL(s)`);
  if (offHost) warn(`${offHost} URL(s) on a different protocol or host than the sitemap: fine only for a cross-site sitemap listed in that site's robots.txt or submitted for a verified property`);
  if (aboveDir) warn(`${aboveDir} URL(s) outside the sitemap's folder: Google applies them only if you submit the sitemap in Search Console`);
  if (badDate) bad(`${badDate} <lastmod> value(s) not in W3C Datetime format`);
  if (out.kind === 'sitemapindex' && locs.includes(at)) bad('the index lists itself (nested index)');
  if (!/xml/i.test(out.type)) note(`served as ${out.type}`);
  return out;
}
 
if (import.meta.url === `file://${process.argv[1]}`) {
  for (const url of process.argv.slice(2)) {
    const r = await check(url);
    console.log(`\n${r.url}\n  HTTP ${r.status ?? '-'}  ${r.type ?? ''}  ${r.kind ?? ''}  entries: ${r.entries ?? '-'}  size: ${r.mb ?? '-'} MB`);
    for (const n of r.notes) console.log(`  note: ${n}`);
    for (const w of r.warnings) console.log(`  WARNING: ${w}`);
    console.log(r.problems.length ? r.problems.map((p) => `  PROBLEM: ${p}`).join('\n') : '  no problems found');
  }
}

It prints each problem as PROBLEM (something Google lists as an error), WARNING (allowed in some setups) or note. We tested it on files we broke on purpose, eight faults in all: an unescaped &, a relative URL, a bad date, a wrong namespace, an HTML error page, an empty file, a robots.txt block and a missing file. It caught each one.

Our test: 14 real sitemaps

On November 16, 2026, we took the first sitemap listed in the robots.txt of 12 sites, plus a likely address for two sites whose robots.txt lists none (Ahrefs and the Guardian), and ran the script. They include government, news, retail and SEO tool sites in several countries, and the platforms behind many small business sites:

SiteTypeEntriesResult
thesearchpost.com (this site)sitemap88No problems
wordpress.orgindex3No problems
yoast.comindex21No problems
allbirds.com (a Shopify store)index8No problems
wix.comsitemap10,946No problems
squarespace.comsitemap6,368No problems
gov.ukindex36No problems
abc.net.au (gzip file)index104No problems
thehindu.com (news sitemap)sitemap447Warning: URLs outside the sitemap's folder
ikea.comindex2,258No problems
moz.comindex55No problems
semrush.comindex23Warning: 7 entries on other subdomains
ahrefs.comindex8No problems
theguardian.com (news sitemap)sitemap339Warning: URLs outside the sitemap's folder

None of the 14 had a blocking problem. The three warnings are the setups Google allows when a sitemap is submitted in Search Console: news sitemaps kept in a subfolder, and an index listing language subdomains and a careers site. We can't see those sites' Search Console accounts, so we can't say how they submit them.

Before we read the robots.txt files, we had guessed addresses for some of these sites, and three returned 404: /sitemap.xml on ABC Australia (its real index is a .gz file in /sitemaps/), /sitemap_news.xml on CBC, and /news/wp-sitemap.xml on WordPress.org. That is the wrong-address cause in miniature: the sitemap exists, just not where we looked. Submit the address your robots.txt or your CMS gives, not the one you assume.

The lesson for a site owner: big sites on WordPress, Shopify, Wix and Squarespace serve sitemaps that pass. If yours shows "could not be read", the cause is almost always one of the five on Google's list, on your own site, and the live URL Inspection test will name it.

What we don't know

Google doesn't say how long it retries before it stops ("a few days"), or what level of crawl demand is too low. Our script checks the file from our own connection, not from Google's crawlers, so a block aimed only at Google's addresses won't show up in it. For related indexing problems, see our guides to crawled, currently not indexed and duplicate without user-selected canonical.

Sources

Photo of Kiran Dasgupta

About the author

Kiran Dasgupta, Editor

Kiran runs Kihan Marketing, a web design, SEO and ads agency, and manages dozens of websites across real estate, home services and healthcare. He writes about SEO, AI search and paid ads news, and what it means for the people who run websites.