|How Should I Structure My URL?|
| 1:23 am on Aug 6, 2013 (gmt 0)|
I'm having the hardest time deciding how to structure my URL for the best SEO.
Basically, I have a deal that I want crawled.
The article is about "How to get 50% blue widgets."
The 732226 is so I can identify which article to pull up, but if it's better to remove it.. I can do so.
(I read on the Google SEO doc that it's good to have a subfolder)
(Amazon and Bestbuy has it this structure, but they may be a special case)
4. None of the above
Any advice would be appreciated
[edited by: bill at 3:01 am (utc) on Aug 6, 2013]
[edit reason] use example.com - use "widgets" for keywords [/edit]
| 3:32 am on Aug 6, 2013 (gmt 0)|
Thanks bill for the edit
| 5:08 am on Aug 6, 2013 (gmt 0)|
Honestly there's not enough of a difference to bother about. Do whatever is easiest for you to code. If you can make a workable URL without a fistful of numbers (your 732226 here), then definitely do that.
|I read on the Google SEO doc that it's good to have a subfolder |
? Whether that's true or not-- and whether you've interpreted it correctly or not-- it's irrelevant here because all your permutations already have at least two pseudo-directory nests. The question seems to be what order to put them in.
I say "pseudo-directory" assuming that none of these configurations represent a real physical file. But there's not much sense in having a directory that contains only one subdirectory.
Putting /deals/ first implies more than one article on the theme of "deals". Putting /How-to-get-etcetera/ first implies you'll be covering more than one aspect of how-to-get.
Second assumption is this one article exists in a perfect vacuum. But really it's connected to an existing site, isn't it? Where is it most logically linked from? If it's an offshoot of any existing page, then its URL should reflect that. If it links primarily from the front page, then what are all the extra directories for?
| 11:46 pm on Aug 7, 2013 (gmt 0)|
welcome to WebmasterWorld, spoofee!
I would avoid using underscores as word separators in urls.
I would also avoid mixed case in url paths as in your title slug.
you should concern yourself with url canonicalization when relying on a unique identifier in the url.
if an arbitrary title slug in the url yields a 200 OK you have a problem.
| 6:26 am on Aug 8, 2013 (gmt 0)|
I avoid "fake folder levels that are meaningless".
You have this URL:
The final folder level implies that you might have other valid URLs like:
which will also be valid.
I prefer the number at the front.
I use all lower case.
I never use underscores as separators.
I don't know the structure of the rest of the site, but I would likely change the deals folder to a 'd' prefix (and other folders to similar 1 or 2 letter prefixes):
The 'd' prefix is used to quickly match the correct rewrite (and quickly reject the others, at the first character). The number and the words are then extracted and passed to the PHP script. The PHP script must look in the database to see if record 732226 exists. If it does not exist, send 404 HEADER and "include" the HTML file with the human-readable error message. If 732226 exists in the database, extract the "name" from the database and compare it with the requested name. If it is not an exact match, send a 301 HEADER and redirect to the correct URL (using the requested number and the name as extracted from the database). If the requested name does match the requested number, serve the content.
The above technical steps are vital. They prevent Duplicate Content issues and avoid the site being flagged for "soft 404" problems.
The front-loaded number also allows corrupted URL requests such as
and shortened URL requests such as
to be processed, redirecting to the correct URL.
Indeed, you effectively also have your own URL shortener and can post URLs such as
elsewhere knowing they will work just fine, redirecting to the correct URL.
You'll run into many people that say "put the number at the end, you need the words first for 'better SEO'". I don't believe it makes all that much difference. However, having the numbers at the front leads to better rewrite efficiency (faster pattern matching) and better functionality (redirecting corrupted and shortened URLs).
This topic has come up several times so far this month. There may be additional useful details in those other threads.