Subdomain or subdirectory? How Google treats each, and which to use

In briefblog.example.com or example.com/blog? How Google handles subdomains and subdirectories, where they differ in practice, and how we decide for each project.

A subdirectory is a folder on your main domain (example.com/blog). A subdomain is a separate host name in front of it (blog.example.com). Google has said for years that it can rank either and does not inherently favor one. The practical difference is how clearly a section reads as part of your main site: a subdirectory is understood as the same site immediately, while a subdomain that looks like a separate site may be treated more like one. So content meant to build your main site's visibility, such as a blog, guides or location pages, usually belongs in a subdirectory, and genuinely separate systems like apps, stores on other platforms or help centers fit naturally on subdomains.

The difference in one table

Subdirectory (example.com/blog)Subdomain (blog.example.com)
How it reads to GoogleClearly part of the main siteSame organization, but can be treated more like a separate site
Shared reputation and linksSimple and immediateIndirect, through links and signals between the two
Internal linkingNatural, same navigationCross-host links; often a separate navigation
Technical setupSame platform, or a reverse proxySeparate DNS record; any platform
Analytics and Search ConsoleOne propertyDomain property covers it; separate URL-prefix properties possible
Site name in Google resultsUses the main site's nameCan have its own site name
Best forBlogs, guides, services, locations, resourcesApps, portals, hosted stores, help centers, separate brands

How Google actually handles each

Subdirectories

A subdirectory is just a path on your domain. Google crawls it as part of the same site, it inherits your site-wide signals, and everything you publish there contributes to how Google understands your site's topics. Internal links from your home page and navigation flow into it naturally.

Subdomains

Technically, a subdomain is a different host. Google can and does understand that it belongs to the same organization, especially when the two are well linked and share branding. But a subdomain that runs on different software, uses a different design and is rarely linked from the main site can end up treated much like a separate website, building its own reputation more slowly.

One visible difference is documented by Google: site names in search results are supported for domains and subdomains, but not subdirectories. A subdomain like news.example.com can show its own site name; example.com/news shows the main site's name.

What Google does not do

Google does not apply a penalty or a bonus for either choice. The SEO case for subdirectories is about consolidation and clarity, not a rule. You will find case studies where moving a blog from a subdomain to a subdirectory lifted traffic; treat them as evidence that consolidation often helps, not as a guarantee.

When to use a subdirectory

Use a subdirectory for anything that should strengthen your main site in search:

  • Blog and articles (/blog)
  • Service and location pages (/services/roof-repair, /locations/naperville)
  • Guides, glossaries and resources (/glossary, /guides)
  • Landing pages for campaigns
  • Language or country versions, where you want one site with hreflang (/es/, /en-ca/)

This is how we structure the sites we build, including this one: the blog, glossary, industries and the agency directory all live under one domain.

When a subdomain makes sense

Use a subdomain when the section is genuinely separate, usually because it runs on a different system:

  • Web apps and customer portals (app.example.com, portal.example.com), which often should not be indexed anyway.
  • Stores on a hosted platform (shop.example.com on Shopify) when your main site runs on something else. See DIY ecommerce: why you should probably use a platform.
  • Help centers and documentation run by a support tool (help.example.com).
  • Careers sites hosted by an applicant tracking system (jobs.example.com).
  • Staging and test sites (staging.example.com), always blocked from indexing. See staging site.
  • Separate brands or audiences that should build their own identity.

Can you put a separate platform in a subdirectory?

Often, yes. A reverse proxy lets example.com/blog serve content from a different system, for example a WordPress blog behind a Next.js marketing site, or a headless CMS feeding pages into your main front end. Netlify, Vercel and Cloudflare all support rewrites or proxies for this. It takes more setup and testing than a subdomain, so weigh it against how much the content matters for search. We explain the headless approach in what is a headless CMS.

Watch out for third-party content

Some sites rent out a subdirectory or subdomain to a partner, such as a coupon section or sponsored reviews, to borrow the main site's reputation. Google's site reputation abuse policy targets third-party content published to exploit a host site's ranking signals. Moving it to a subdomain does not make it acceptable. Only publish content you would stand behind as your own.

Moving between the two

If you are moving a blog from a subdomain into a subdirectory (or the reverse):

  1. Map every old URL to its new address.
  2. Set up 301 redirects for each page, not just a blanket redirect to the home page. See 301 redirect.
  3. Update internal links, canonicals and your XML sitemap.
  4. Verify both in Google Search Console and watch indexing for a few weeks. A Domain property, verified by DNS, covers all subdomains in one view.
  5. Expect some short-term movement while Google processes the change.

Our guide to redesigning a website without losing SEO covers the full checklist.

Tracking and analytics

  • Search Console: add a Domain property to see the main site and every subdomain together, plus URL-prefix properties if you want each section separately. For submitting sitemaps, see optimizing an AI-built site for search and AI.
  • Google Analytics 4: one data stream can cover subdomains of the same domain; check that your cookie domain and referral exclusions are set so a visitor moving between them counts as one session.
  • Consistency: keep branding, navigation and your business details the same across both. See why NAP+W consistency matters.

How we'd decide

  • Content meant to rank and support your brand: subdirectory.
  • A separate product, app, portal, store or tool on another platform: subdomain, unless a reverse proxy is practical and the content matters for search.
  • A separate brand or audience: subdomain or separate domain.
  • Anything not meant for search (staging, internal tools): subdomain, blocked from indexing.

Planning a site structure or a migration? Talk to us before you move anything, because redirects are much easier to plan than to repair.

Questions people ask

Does Google rank subdirectories higher than subdomains?
Google has said for years that it does not inherently prefer one over the other and can work with either. In practice, a subdirectory is understood as part of your main site straight away, while a subdomain that looks like a separate site may be treated more like one, so content that should build on your main site's reputation is usually safer in a subdirectory.
Should my blog be on a subdomain or a subdirectory?
For most businesses, a subdirectory such as example.com/blog. The blog's content supports the same brand and topics as the rest of the site, internal linking is simpler, and everything lives in one analytics and Search Console view. A subdomain makes sense mainly when the blog has to run on a separate platform that cannot be served under your main domain.
When is a subdomain the better choice?
When the section is genuinely a separate product or system: a web app or customer portal, a store on a hosted ecommerce platform, a help center, a careers site run by an applicant tracking system, a separate brand or regional site, or a staging site that should not be indexed.
Do subdomains share SEO authority with the main domain?
Partly and indirectly. Links between the main site and the subdomain pass signals like any internal or cross-site link, and Google can understand that they belong to the same organization. But a subdirectory benefits more simply and immediately because it is clearly part of the same site.
How do I track a subdomain in Google Search Console?
Add a Domain property, verified by DNS, which covers every subdomain and both http and https. You can also add each subdomain as its own URL-prefix property to see its data separately.

Planning a website?

Get a platform recommendation and a fixed quote within one business day.

Start a project

Tell us what the site needs to do.

Share a few details and a budget range. We reply within one business day with a plan, a platform recommendation and a fixed quote.