deindexwebsites.com

Scope: staging, subdomains, directories

How to Deindex a Subdomain Without Touching the Main Site

A subdomain is a separate host as far as crawling and removals are concerned. That is helpful, because you can act on it alone, but it means nothing you do on the main site reaches it.

By the deindexwebsites.com editorial team · Updated

Why subdomains behave independently

Google's Removals tool help is explicit: prefix removal blocks every URL starting with a given path across the www/non-www and http/https variants, but subdomains such as staging. are not affected. The reverse is also true. A prefix removal for https://blog.example.com/ does nothing to https://www.example.com/. This isolation is what lets you delist one subdomain safely.

Typical reasons

  • A retired blog, help centre or forum on blog., help. or forum.
  • A product microsite that ended
  • A tenant or customer subdomain from a multi-tenant app
  • A staging or preview host that leaked
  • A wildcard DNS record that answers for any subdomain, creating junk hostnames

Plan before acting

Answer these four questions first.

  1. Does the subdomain need to keep working for users? If yes, noindex. If it is going away, 404/410. If it moved, 301.
  2. Is it hosted separately? If the subdomain runs on a different server or platform, you apply the signal there, not on the main site.
  3. Do other properties link to it? Internal links, sitemaps and embeds all keep it discoverable.
  4. Does the main site share files with it? Shared CDN paths, shared robots.txt logic or shared templates can accidentally apply your change to both.

Step-by-step

  1. Get ownership. Verify a Domain property by DNS, or a URL-prefix property for the subdomain. If a parent property is already verified, its child properties verify using the parent's method.
  2. Deploy the permanent signal on the subdomain's server. For noindex use X-Robots-Tag: noindex for all paths; see site-wide noindex. For a dead subdomain, return 410 or 404 for every path; see 410 for an entire site.
  3. Submit the temporary removal. Choose the subdomain property, then Removals, new request, remove all URLs with this prefix, and enter https://sub.example.com/. Do this for http:// too if it ever served content.
  4. Remove internal links to the subdomain from the main site, or redirect them to a relevant live page if the content has a true successor.
  5. Update sitemaps. Remove the subdomain's URLs from any sitemap on the main site. Cross-host sitemaps can keep the subdomain in play.
  6. Watch the reports and confirm via URL Inspection.

Wildcard DNS and junk subdomains

If your DNS has a wildcard record, any hostname answers. Spam bots and scrapers sometimes link to made-up subdomains of a real domain, and Google may discover them. Symptoms: Search Console shows indexed pages on hostnames you never created. The fix is at the server, not in Search Console: configure the default virtual host to return a 404 or 444-style close (or a 410) for unknown hostnames, and ensure real hostnames are explicitly listed. Then request removals for the junk hosts you can verify; a Domain property covers them without individual verification.

Subdomain versus subdirectory decisions

If you are consolidating a subdomain into the main site, deindexing is not the right move; redirecting is. Use 301s from the old URLs to their equivalents and follow Google's site move guidance, which advises keeping redirects for as long as possible, generally at least a year. Only use a removal when there is no sensible destination.

GoalAction
Subdomain content merged elsewhere301 to equivalents
Subdomain content gone, no replacement410 or 404
Subdomain live but unlistedNoindex header
Subdomain sensitiveAuthentication

Robots.txt on the subdomain

Each hostname has its own robots.txt. A permissive robots.txt on the main domain does not apply to the subdomain, and vice versa. That also means a Disallow: / on the subdomain stops Google from reading your noindex there. Keep the subdomain's robots.txt open until the pages drop out. See robots.txt mistakes.

Check for shared assets

If your subdomain hosts images, scripts or downloads used by the main site, deindexing or removing the subdomain may break them. Search the main site's source for the subdomain hostname before changing anything, and move shared assets first.

Verification checklist

  • Subdomain signal confirmed with a header check on three paths
  • Removal request visible in the Removals report
  • No sitemap on any host lists the subdomain
  • site:sub.example.com shrinking over time
  • Main site traffic and indexing unchanged
  • Calendar reminder at five months to confirm the permanent signal is still live

Example: retiring a help-centre subdomain

A company moves support content into its main site and wants help.example.com gone. The content has direct equivalents for about half the articles. The team redirects those one to one, serves 410 for the rest, removes the subdomain from the main site's navigation and sitemap, and files a prefix removal on the subdomain's property. They leave robots.txt on the subdomain permissive for now so Google can see the redirects and 410s. After the Pages report shows the URLs as redirects and not found, they stop worrying about it and calendar a check at the five-month mark.

Notice the split: equivalents get redirects, orphans get 410, and nothing gets a blanket redirect to the homepage.

Questions that catch problems early

  1. Does anything on the main site embed images or scripts from the subdomain?
  2. Do emails or documents still link to it?
  3. Is the subdomain used for authentication cookies shared with the main site?

Frequently asked questions

Will deindexing a subdomain hurt the main domain?

Not by itself, since each host is handled separately. But if the subdomain carried links or traffic the main site relied on, you may lose that value.

Does a Domain property let me remove all subdomains at once?

It gives you visibility across them, but plan removals per hostname because prefix removal does not extend to subdomains.

What if I cannot reach the subdomain's server?

You still need a permanent signal. Without it the removal expires. Regain access or have the host apply it.

Should I redirect a dead subdomain to the homepage?

Generally no. Redirects to irrelevant pages can be treated as soft 404s. Use 410 or redirect each URL to a genuine equivalent.

Official sources

Keep reading