Skip to content

WordPress pages not getting indexed by Google: diagnosis

Diagnose WordPress pages not indexed by Google by reading each Search Console Page indexing status literally, then confirming the cause from the site side with curl.

Search Console already tells you where a URL fell out of Google’s pipeline. The trick is to read the status literally instead of treating everything under “Not indexed” as one problem. “Blocked by robots.txt” and “Excluded by ‘noindex’ tag” are your doing and usually fixable in minutes. “Page with redirect” and “Duplicate without user-selected canonical” are normally URL hygiene left over from a migration. “Discovered – currently not indexed” and “Crawled – currently not indexed” are not bugs at all — they are Google declining, for now, to spend crawl or index budget on that page. Indexing is a decision Google makes, not a setting you flip, and no amount of technical tidying makes a thin page worth indexing.

What you’ll accomplish

  • Map each Page indexing status onto the pipeline stage the URL failed to clear, instead of guessing at causes.
  • Confirm from the site side — with curl, not a plugin dashboard — whether a page returns 200, carries a noindex directive, and canonicalises to itself.
  • Find the WordPress-specific causes: the Settings > Reading checkbox, SEO-plugin rules on archives and taxonomies, an indexed staging host, canonicals stuck on the old domain, and parameter sprawl.
  • Separate the problems you can fix from the ones that are Google’s call, and stop spending time on the second kind.

Prerequisites

  • A verified Search Console property that covers the exact host you care about. A URL-prefix property for https://www.example.com/ says nothing about https://example.com/. If you are chasing a canonical or migration problem, use a Domain property so every host and protocol variant lands in one report.
  • Administrator access to the WordPress site, because two of the six causes below are settings, not code. Shell access with WP-CLI makes several checks faster but is not required.
  • curl on your own machine. Every check in this guide runs against the reader’s own public site from outside it, which is the point: you want to see what a crawler sees, not what the admin sees.

How it works

Google’s crawlers work through four stages, and each Page indexing status is a statement about which stage a URL never got past. Discovery puts a URL in a queue — it comes from an internal link, an external link, or a sitemap. Crawling is the actual fetch, and it happens only if robots.txt allows it. Rendering runs the HTML and any JavaScript so that directives written by a plugin into the head are visible. Indexing is the last step and the only one that is not mechanical: Google decides whether the page earns a slot, and which URL in a group of near-duplicates represents it.

Four-stage pipeline showing where a URL drops out — discovered, crawled, rendered, indexed — with the Search Console status reported at each stage

Two consequences matter for WordPress operators. First, robots.txt controls crawling, not indexing. A URL you disallow can still be indexed if other sites link to it — Google’s robots.txt introduction states this plainly. Worse, disallowing a URL guarantees Google never reads the noindex you put on it, so the two directives cancel each other out. If you want a page out of the index, let Google crawl it and serve noindex.

Second, the crawl stage is rate-limited by how your server behaves. A WordPress site that answers in 90 ms gets crawled at a very different rate than one that answers in 2.5 s under load, and “Discovered – currently not indexed” on a large site is often a crawl-capacity story rather than a content one. Google’s crawler overview documents which agents fetch what; if you are tuning for crawl rate, start with measuring WordPress TTFB across the request lifecycle.

Step-by-step

Decision table mapping each Search Console Page indexing status to the first check to run on the WordPress side

1. Pull the status before you touch anything. In Search Console, open Indexing > Pages and read the “Why pages aren’t indexed” table. Pick one representative URL per status and run URL Inspection on it. Note the exact status string and the Google-selected canonical. Everything below is a confirmation step for a status you already have — diagnosing without one is how people end up “fixing” a page Google was never blocked from.

2. Check the response code the crawler actually gets. Anonymous, uncached, from outside:

curl -sS -o /dev/null -w 'status=%{http_code} redirect=%{redirect_url}\n' https://example.com/target-page/
status=200 redirect=

A 200 with an empty redirect field is what an indexable page looks like. A 301 or 302 here is the whole explanation for “Page with redirect”. A 404 or 410 explains “Not found (404)”. If you get a 403, a WAF or a bot rule is refusing the request — repeat with -A 'Googlebot' to see whether the block is user-agent conditional, then fix the rule rather than the page.

3. Read the response headers for an X-Robots-Tag. This is the check people skip, because the header is invisible in the WordPress admin and is usually set in .htaccess, an nginx config, or a security plugin:

curl -sSI https://example.com/target-page/ | grep -i -e '^HTTP/' -e '^x-robots-tag'
HTTP/2 200

No x-robots-tag line is the healthy result. If it prints x-robots-tag: noindex, that alone produces “Excluded by ‘noindex’ tag” and no meta tag edit will override it — the header wins because it is applied before the document is even parsed. This is a common leftover on hosts that ship a staging-protection rule and forget to remove it at launch.

4. Read the rendered meta robots tag and the canonical. Fetch the document and pull both directives out of the head:

curl -sS https://example.com/target-page/ | grep -i -o -E '<meta[^>]*name="robots"[^>]*>|<link[^>]*rel="canonical"[^>]*>'
<link rel="canonical" href="https://example.com/target-page/" />

Two things to confirm. There should be no noindex in a robots meta tag, and the canonical href should be the same absolute URL you requested — same scheme, same host, same trailing slash. A canonical pointing at http://, at staging.example.com, or at the pre-migration domain is exactly what produces “Duplicate without user-selected canonical”, because you have told Google the real page lives somewhere else. Note that this fetch does not run JavaScript; if your theme injects directives client-side, compare against URL Inspection’s rendered HTML.

5. Confirm WordPress itself is not discouraging crawlers. Settings > Reading has a checkbox labelled “Discourage search engines from indexing this site”. It is one option row in the database:

wp option get blog_public
1

1 means the site is open to search engines. 0 means the checkbox is ticked, WordPress is emitting a site-wide noindex, and every page will report “Excluded by ‘noindex’ tag”. Without shell access, look at the checkbox directly, or confirm from the outside using step 4 on the home page.

6. Fetch robots.txt as a crawler would. WordPress serves a virtual robots.txt unless a real file exists at the document root, in which case the file wins and the WordPress filter is bypassed entirely:

curl -sS https://example.com/robots.txt
User-agent: *
Disallow: /wp-admin/
Allow: /wp-admin/admin-ajax.php

Sitemap: https://example.com/wp-sitemap.xml

That is a healthy default. Disallow: / is a site-wide block and explains “Blocked by robots.txt” for every URL. Check for narrower rules too — a Disallow: /shop/ added during a promotion, or a Disallow: /*?* that quietly removes every filtered archive from crawling.

7. Fetch the sitemap and read what it actually lists. WordPress 5.5 and later serves a sitemap index at /wp-sitemap.xml; Yoast and Rank Math replace it with /sitemap_index.xml:

curl -sS https://example.com/wp-sitemap.xml | grep -o -E '<loc>[^<]+</loc>' | head -20
<loc>https://example.com/wp-sitemap-posts-post-1.xml</loc>
<loc>https://example.com/wp-sitemap-posts-page-1.xml</loc>
<loc>https://example.com/wp-sitemap-taxonomies-category-1.xml</loc>

Then open one child sitemap and confirm the URL you are chasing is in it, spelled exactly as it resolves. A sitemap that lists http:// URLs, old-domain URLs, or URLs that 301 is a steady source of confusing statuses, because you are repeatedly telling Google to index addresses you have already retired.

8. Follow the chain when the status is “Page with redirect”. Sitemaps and internal links should point at the final URL, never at a hop:

curl -sSIL -o /dev/null -w '%{http_code} %{url_effective}\n' https://example.com/old-page/
200 https://example.com/new-page/

If this ends anywhere other than the URL you submitted, the submitted URL is not the one to chase — inspect the destination instead. Permalink structure changes are a frequent source of these hops; see how permalink structure affects SEO before changing it again.

Validate it works

A page that is genuinely eligible for indexing passes four checks at once: it returns 200 to an anonymous request, has no noindex in either the X-Robots-Tag header or a robots meta tag, carries a self-referencing absolute canonical, and appears in a sitemap that Search Console has accepted. Run steps 2 through 4 again after any change and confirm all four in one pass.

Then request indexing through URL Inspection once, and stop. Requesting again does not move the URL up a queue. Google re-crawls on its own schedule, which can be hours for an active site and weeks for a quiet one, and there is no supported way to force or accelerate indexing. If the status was “Excluded by ‘noindex’ tag” and you removed the directive, you have made the page eligible — you have not made it indexed, and the two are different claims. Watch the Page indexing report over the following weeks rather than refreshing it daily.

Troubleshooting

The Discourage checkbox was never unticked after launch. A site built on a staging host with “Discourage search engines” on, then pushed to production by copying the database, carries blog_public = 0 with it. Every URL reports “Excluded by ‘noindex’ tag” and the site looks catastrophically broken to whoever inherits it. Fix it in Settings > Reading, or with wp option update blog_public 1, then verify from outside with step 4 — some caching layers will keep serving the old HTML with the directive baked in until you purge.

The SEO plugin is noindexing a whole post type or taxonomy. Yoast and Rank Math both expose per-post-type and per-taxonomy indexing switches, and both default several archive types to noindex. That default is often correct — tag archives with two posts each really should stay out. It stops being correct when someone flips the switch on a post type that carries real landing pages, or when a WooCommerce product attribute archive is doing genuine work. Check the plugin’s search-appearance settings per type rather than per post, then re-run step 4 on one URL of that type.

A staging copy is indexed instead of production. If URL Inspection reports a Google-selected canonical on a different host, a crawlable staging or www-versus-apex duplicate exists. Do not fix this by disallowing the staging host in robots.txt — that blocks the crawl and leaves the already-indexed URLs in place. Put HTTP authentication in front of staging so it returns 401, or serve X-Robots-Tag: noindex there and let Google crawl it once more to see the directive.

Canonicals still point at http:// or the old domain. After a domain move or an HTTPS migration, canonical URLs stored in post meta or generated from a stale siteurl keep pointing at the old address. Every page then reports “Duplicate without user-selected canonical” or gets folded into a host that no longer exists. Confirm with step 4, then correct siteurl and home and run a proper serialisation-aware search-and-replace across the database rather than a SQL UPDATE.

The sitemap lists URLs that redirect or 404. Manual sitemap plugins, cached sitemap files, and CDN-cached XML all go stale. Google keeps fetching the stale list, keeps landing on redirects, and keeps reporting “Page with redirect” against URLs you retired months ago. Regenerate the sitemap, purge it from the CDN, confirm with step 7, and make sure the sitemap source is the live post list rather than a saved file.

When this is the wrong approach

If the status is “Crawled – currently not indexed” across a large group of similar URLs, there is no technical fix to find. Google fetched those pages, read them, and decided they did not earn a slot. Thin tag archives, near-duplicate location pages, paginated series where every page repeats the same intro, and parameter permutations of the same product list all land here, and the honest response is consolidation: merge the thin pages into one substantial page, canonicalise the parameter variants to the clean URL, and accept that fewer indexed pages of higher value is the goal. Forcing them into the index is not on the menu, and pursuing it produces the kind of scaled thin content that costs you far more than the missing URLs did.

Brand-new sites are the other case. A site published three weeks ago with a handful of internal links and no external ones will show large “Discovered – currently not indexed” counts, and that is the system working as designed. Publish, link internally, earn a few real references, keep the server fast, and let the queue drain. There is no configuration change that shortens this, and any tool that claims otherwise is selling you something.

Running WordPress that earns real money deserves an operator — Stack Harbor runs that stack under enterprise WordPress support; book an infrastructure consult.