4

Possible Duplicate:
SEO : urls : best place for the id

My site uses URL rewriting in both formats (for different things), but I'm wondering which one is the better approach?

  1. http://www.example.com/695/title-goes-here
  2. http://www.example.com/title-goes-here/695.html
  • 1
    The file extension is one of the main things you want to remove when rewriting, because it may change in the future and you don’t want your URL to change, and because it is technical backstage stuff you don’t need to show to the user. – Simon White Feb 4 '16 at 18:19
3

Take a look at the URL of this page. It closely matches option #1.

I'm not sure if there is a limit to how long a URL search engines will index but if they do have a limit and your URL exceeds it then the ID (695 in your example) will be truncated and the page will become in accessible to them. Having the ID early in the URL will ensure they can always access the page.

  • agreed, but does approach #2 add any SEO benefits? (more than #1)? – siliconpi Feb 26 '11 at 15:55
  • @matt_tm - Have more of an SEO benefit? No. – John Conde Feb 26 '11 at 16:21
  • @JohnConde does your answer contain an assumption that developers of SE made the best choice as opposed to merely a practical choice? – Evgeny Aug 11 '13 at 3:56
1

Approach #1 intuitively seems better. That's because logically, the middle of the domain is indicative of a "content hierarchy" and the last portion signifies what the actual content is.

Not the answer you're looking for? Browse other questions tagged or ask your own question.