URL Structure
Last updated View as Markdown
URL structure is a low-weight ranking signal but a high-weight usability signal. Clean, descriptive URLs reinforce topical relevance, improve click-through rate, and make a site significantly easier to maintain. Bad URL structure is a common source of SEO migration disasters.
What does good URL structure look like?
https://seohandbook.co.uk/on-page-seo/title-tags/
The pattern:
- HTTPS protocol
- Short, lowercase domain
- Clear category in the path (
/on-page-seo/) - Specific page slug at the end (
/title-tags/) - No file extensions, no query parameters for canonical pages, no session IDs
- Trailing slash applied consistently across the site
Conventions that consistently perform
Use lowercase. Mixed-case URLs are technically distinct from lowercase versions on most servers and can cause duplicate content issues. Lowercase universally.
Hyphens, not underscores. Google recommends hyphens “instead of underscores” to separate words, “as it helps users and search engines better identify concepts in the URL”, and notes that underscores are conventionally used to hold a concept together, as in a function name like format_date.1 core-web-vitals reads as three words; core_web_vitals reads as one.
Keep slugs short. A slug should be the shortest accurate description of the page content. Stop words (“a”, “the”, “and”, “of”) can usually be omitted without loss of meaning. core-web-vitals is better than what-are-the-core-web-vitals-and-why-do-they-matter.
Reflect site structure in the path. A URL like /technical-seo/core-web-vitals/ tells the user (and search engines) that the page is part of the technical SEO category. Flat URL structures (/core-web-vitals/) work for small sites but lose informational value as the site grows.
Include the target keyword naturally. The slug should contain the target keyword if it can be done without forcing. Don’t keyword-stuff URLs; one natural keyword inclusion is enough.
Be consistent with trailing slashes. Either always use them or never. Astro defaults to trailingSlash: 'always'; Next.js defaults to no trailing slash. Pick one, configure the framework accordingly, and add 301 redirects from the alternate form.
URLs are case-sensitive
Google treats /Page and /page as two different URLs, as its URL structure guidance states, so mixed-case links can split ranking signals or create duplicate paths that compete with each other. Keep every indexable, navigable URL lowercase, and 301 any mixed-case variants to the lowercase version. It also makes URLs easier to share and type without errors.
What to avoid
| Pattern | Problem |
|---|---|
Dynamic IDs (/article?id=4837) | No semantic meaning; weaker for ranking and CTR |
| Date-based URLs for evergreen content | URLs imply staleness; rewrites are awkward |
File extensions (.html, .php) | Couples URL to implementation; fragile across migrations |
| Mixed case | Server-side duplicate content risk |
Excessive depth (/category/subcategory/sub-subcategory/page/) | Diluted authority; user-hostile |
| Stop-word-heavy slugs | Longer URLs without added meaning |
| Tracking parameters in canonical URLs | Indexing fragmentation |
URL structure and migrations
A major risk in any site rebuild is URL changes that aren’t properly redirected. The core steps:
- Inventory existing URLs. Crawl the live site (Screaming Frog, Sitebulb) and export the full URL list with response codes.
- Map old URLs to new URLs. Every URL that changes needs an explicit 301 redirect to the new equivalent. Bulk pattern-based redirects (regex) are fine for predictable transformations; one-to-one mapping is necessary for irregular changes.
- Test the redirect map. Spot-check critical URLs (homepage, top-traffic pages, top-converting pages) and verify each returns a 301 (not 302) to the correct destination.
- Monitor post-launch. Watch Search Console for crawl errors and indexing drops in the weeks after launch. Some loss is normal; sustained loss indicates redirect or canonicalisation problems.
Migrations done badly cost months of organic traffic. Migrations done well still take time to settle: Google’s internal estimate for a site move is one to three months typically, and a few weeks for a small site.2
URL parameters
Parameters are fine for filtering and sorting interfaces, provided the canonical version of each page is set explicitly. The patterns:
- Allow parameters when each parameter combination represents a genuinely distinct page (paginated archives, faceted filters with unique inventory).
- Set canonicals to the parameter-stripped or canonical-parameter version when multiple URL variants serve substantially the same content.
- Canonical tags and
robots.txtDisallowrules are the reliable approaches. Google removed the URL parameters tool from Search Console in April 2022; it no longer exists.3
Subdomains vs subdirectories
The long-running debate. Google documents no ranking advantage either way, but “Google’s official position is that they are equivalent” overstates what it has actually published. Its ranking systems guide says site diversity “generally treats subdomains as part of a root domain” while adding that “sometimes subdomains are treated as separate sites” when Google judges it relevant,4 and its crawling infrastructure “defines a site as a unique hostname”, giving each subdomain its own crawl budget.5 Site architecture covers the three places that boundary shows up. In practice, many SEOs prefer subdirectories on the view that a subdomain can be assessed as a somewhat separate property, so keeping content under example.com/blog/ consolidates its signals with the main site rather than splitting them off to blog.example.com. The evidence for that view is correlational, and Google’s SEO Starter Guide lists the choice among the things it believes you shouldn’t focus on.6 Subdirectories remain the simpler default for most sites, because one host is easier to maintain.
Use subdomains when there is a genuine technical or organisational reason: a multi-tenant SaaS product where each tenant needs a distinct domain, or a logically distinct property with a separate user audience. For international sites deciding between ccTLDs, subdomains, and subdirectories, see International URL Structure.
Frequently asked questions
Does URL length affect rankings?
No direct effect. Shorter URLs correlate with better performance in some studies, but that is almost always confounded by other factors rather than a length signal in itself. Optimise for clarity first; length follows.
Should I include the year in URLs?
For evergreen content, no. The URL becomes awkward when the content is updated. For news and dated content where the date is part of the topic, including the year can be appropriate.
Are non-English characters in URLs OK?
Yes, Google handles them, but they’re harder to share and copy. For international sites, consider whether transliterated ASCII slugs are more practical than native-character slugs in the URL. Hreflang and language targeting work either way. For guidance on structuring an international site across domains or subdirectories, see International URL Structure.
Footnotes
-
URL structure best practices for Google — Google Search Central ↩
-
Google Search Central Live Deep Dive, Barcelona: Day 3 recap — ROAST. An attendee’s recap of Gary Illyes’s slides, which Google has not published; Estela Franco’s photos of the slides show the same figures. ↩
-
Spring cleaning: the URL Parameters tool — Google Search Central Blog ↩
-
A guide to Google Search ranking systems — Google Search Central ↩
-
SEO Starter Guide — Google Search Central, “Things we believe you shouldn’t focus on” section. ↩