Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 3304328
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 17, 20262026-05-17T21:03:01+00:00 2026-05-17T21:03:01+00:00

In a now migrated question about human-readable URLs I allowed myself to elaborate a

  • 0

In a now migrated question about human-readable URLs I allowed myself to elaborate a little hobby-horse of mine:

When I encounter URLs like http://www.example.com/product/123/subpage/456.html I always think that this is an attempt on creating meaningful hierarchical URLs which, however, is not entirely hierarchical. What I mean is, you should be able to slice off one level at a time. In the above, the URL has two violations on this principle:

  1. /product/123 is one piece of information represented as two levels. It would be more correctly represented as /product:123 (or whatever delimiter you like)
  2. /subpage is very likely not an entity in itself (i.e., you cannot go up one level from 456.html as http://www.example.com/product/123/subpage is “nothing”).

Therefore, I find the following more correct:

http://www.example.com/product:123/456.html

Here, you can always navigate up one level at a time:

  • http://www.example.com/product:123/456.html
    — The subpage
  • http://www.example.com/product:123 — The product page
  • http://www.example.com/ — The root

Following the same philosophy, the following would make sense [and provide an additional link to the products listing]:

http://www.example.com/products/123/456.html

Where:

  • http://www.example.com/products/123/456.html — The subpage
  • http://www.example.com/products/123 — The product page
  • http://www.example.com/products — The list of products
  • http://www.example.com/ — The root

My primary motivation for this approach is that if every “path element” (delimited by /) is selfcontained1, you will always be able to navigate to the “parent” by simply removing the last element of the URL. This is what I (sometimes) do in my file explorer when I want to go to the parent directory. Following the same line of logic the user (or a search engine / crawler) can do the same. Pretty smart, I think.

On the other hand (and this is the important bit of the question): While I can never prevent that a user tries to access a URL he himself has amputated, am I wrongfully asserting (and honouring) that a search engine might do the same? I.e., is it reasonable to expect that no search engine (or really: Google) would try to access http://www.example.com/product/123/subpage (point 2, above)? (Or am I really only taking the human factor into account here?)

This is not a question about personal preference. It’s techical question about what I can expect of an crawler / indexer and to what extend I should take non-human URL manipulation into account when designing URLs.

Also, the structural “depth” of http://www.example.com/product/123/subpage/456.html is 4, where http://www.example.com/products/123/456.html is only 3. Rumour has it that this depth influences search engine ranking. At least, so I was told. (It is now evident that SEO is not what I know most about.) Is this (still?) true: does the hierarchical depth (number of directories) influence search ranking?

So, is my “hunch” technically sound or should I spend my time on something else?


Example: Doing it (almost) right
Good ol’ SO gets this almost right. Case in point: profiles, e.g., http://stackoverflow.com/users/52162:

  • http://stackoverflow.com/users/52162 — Single profile
  • http://stackoverflow.com/users — List of users
  • http://stackoverflow.com/ — Root

However, the canonical URL for the profile is actually http://stackoverflow.com/users/52162/jensgram which seems redundant (the same end-point represented on two hierarchical levels). Alternative: http://stackoverflow.com/users/52162-jensgram (or any other delimiter consistently used).


1) Carries a complete piece of information not dependent on “deeper” elements.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-17T21:03:01+00:00Added an answer on May 17, 2026 at 9:03 pm

    Hierarchical urls of this kind “http://www.example.com/product:123/456.html” are as useless as “http://www.example.com/product/123/subpage”, because when users see your urls, they don’t care about identifiers from your database, they want meaningful paths. This is why StackOverflow puts question titles into urls: “http://stackoverflow.com/questions/4017365/human-readable-urls-preferably-hierarchical-too”.

    Google advices against practice of replacing usual queries like “http://www.example.com/?product=123&page=456”, because when every site develops it’s own scheme, crawler doesn’t know what each part means, if it’s important or not. Google has invented sophisticated mechanisms to find important arguments and ignore unimportant, which means you’ll get more pages into index and there will be less duplicates. But these algorithms often fail when web developers invent their own scheme.

    If you care about both users and crawlers you should use urls like this instead:

    • http://www.example.com/products/greatest-keyboard/benefits — the subpage
    • http://www.example.com/products/greatest-keyboard — the product page
    • http://www.example.com/products — the list of products
    • http://www.example.com/ — the root

    Also, search engines give higher rating to pages with keywords in the url.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Note This originally started as a question about 404 errors, but now it's a
I just right now migrated from C# to C++/CLR. First I was annoyed, that
I've been using hibernate with jboss 4.2.3 and everything was working, now i migrated
I have a moderately complex application using POJOs, and now come to migrated it
I migrated from rails 2.x to 3.x. Now when calling a controller method throws
Now this isn't a question as to which of the technologies is better, since
This is a rails question about migration versions So i have a few migrations
I'm working on a project started in VB9 (VS 2008) and now I've migrated
I have first to explain a little bit my context, then the question: I
I'm troubled by this question for a long time now. I work in the

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.