Let’s discuss URL best practices: frankly, it’s one of the elements of SEO that is easiest to get right (and yet, so SO many issues out there.)
SEO-friendly URLs can & should:
The way that a search engines robot or crawler reads your URL (or: Uniform Resource Locator) can be different than how a human reads it. While you are structuring your website, (say, defining your Information Architecture,) it is very important to create a URL structure that will please your mechanical visitors as well as your human ones. URLs that are too long, include underscores, capital letters, arbitrary numbers or even just look a “little weird” can cause problems in a couple of different ways.
Bad URLs can:
Here’s a guide for insight on what you should look out for when defining your URL structure.
The very first part of the URL - the “http” part of "http://www.example.com." If the website is using the secure protocol, it’ll be “https.” S = secure (at least… more secure.)
If there are multiple periods in your domain, you’ve got a subdomain. It's the “www.” part of "www.example.com."
Your domain name that you (most likely) directly purchased.
.com, co.uk, .org, .gov are all extremely popular ones, but there are 1000s available to choose from. If and when a TLD is country-specific (say, .de for Germany, and .co.uk for the United Kingdom), it's called a ccTLD, or country-code top-level domain.
Really, path describes anything after the first slash after the domain name (including folders.) This is sometimes also called a “relative URL.”
URLs often have a nesting organizational structure. In the example image above, /blog/ is a folder. If we organized blog content by the year it was posted (e.g. /blog/2020/whats-in-an-seo-friendly-url), the /2020/ part would be a sub-folder. It’s basically just the nested part of this parent/child URL structure often used for category and subcategory structuring (picture breadcrumb nesting.)
The same thing as the path, but it specifically refers to the name of the URL after the final slash - or the specific page you are viewing. In the case of assets (images, JS, CSS, etc.) the URL slug is the actual filename of that asset.
The question mark in a URL, and anything after it (hashes being an exception to this rule.) URL Parameters are dynamic URLs that can change page content, but don't always.
The pound sign in a URL, and anything after it. Google will not be able to access unique URLs with hashes in them; only the part of the URL without the hash will be considered. Therefore, they specifically recommends against using hashes in URLs.
That said, the use of hashes is perfectly fine in some cases:
With that in mind - now that we’re all speaking the same “language”, let’s get back to important URL considerations:
Capitalization directly affects the way that search engines index your site. While domains (eg "example.com") are not case sensitive by themselves, URLs are. So when a search engine sees www.yoursite.com/Section-One/ and www.yoursite.com/section-one/ it indexes them as two different web pages.
Two different versions of the same page with the same content will be flagged as duplicate content, which can & does create SEO issues.
Pro-Tip: duplicate content is an issue because - once upon a time - spammers would steal content from other sites & put it on their own sites. Google started penalizing sites with the same content on different URLs to stop this bad practice. URL casing issues are really just a by-product of this original fix.
Similarly, if your URL has uppercase letters, and a user links to a lowercase letters, it could end up as a 404 error - a rare occurrence, but it does happen.
Quick solve? Enforce casing & redirect from one version to the other. I strongly recommend all lower case, all the time. (Aside - you can ignore casing issues in parameters.)
When optimizing a web page for a certain keyword, you want to make sure that there isn't a lot of necessary “filler.” Generally aim for less than or equal to 75 characters (including your domain name) whenever possible. Long URLs are not (at all) inherently better.
As a human, it might be safe to assume that www.yoursite.com/08/09/2011/url-best-practices/ means that yoursite.com published an article about URL best practices on August the 9th, 2011. Search engines will see this and take into account the numbers as well as the words.
The importance of the words can be diluted by the presence of the numbers - and folders - preceding it. Plus - if date is old - the content could be devalued.
General rule of thumb: important pages on your site should have no more than 3 folders. Don’t include folders when they aren’t helpful!
Query parameters increase the overall length of the URL and can lead to duplicate content issues. How faceted URLs on e-commerce websites look is a common problem on e-commerce websites when sorting different products and categories.
Many people recommend dropping sentence articles or so-called "stop words" (e.g. “the”, “a”, etc.) from URLs. We don’t feel strongly about this either way - just keep overall URL length in mind, if and when you do keep them.
More on folder structure, below.
Shorter URLs are also nicer to look at, easier to understand, easier to memorize, read to someone over the phone, type into a mobile device, etc.
The short and sweet difference between these separators:
So the short and sweet recommendation here is: always use hyphens to separate words in URLs.
Caveat: underscore usage in parameters is fine. Parameters really have their own set of rules that are separate!
Having file extensions, like .html, .php, .asp and so on, at the end of your URLs does not appear to have a direct effect on your web page's search engine ranking. That said, there are reasons to remove file extensions from your URLs.
One reason is security. The more information that a malicious user or bot has about how your website is built, the better chance they have of figuring out how to hack it (to be clear, this is not hard to determine anyway, but why make it easier on them?)
Another reason to remove file extensions is the longevity of that URL - with them, every time you change your website’s platform, or the based language, the URL must inherently change. But if URLs are extentionless, they don’t inherently have to change when the technology that drives the changes.
The architecture of your site is very important for many reasons. The way your files are structured makes a difference in how your website is crawled by search engines, as well as “surfed” by a user.
A good rule of thumb to follow is to try to have your most important content within two or three clicks (and folders, as mentioned above) of the home page. Pages that are placed closer to your home page will gain more SEO equity, and therefore more ability to rank.
Proper folder structure should be used, so any pages nested under /products/ should include the folder in their URL, e.g. www.yoursite.com/a-great-product/ should be at www.yoursite.com/products/a-great-product/. This aids usability/user experience in that users always know where they are located on your site.
(Proper folder structure is, in essence, a UX and SEO-friendly URL structure.)
Some sites try to get around the “3 click/folder” rule by making all URLs top-level (i.e. no use of subfolders, with all URL slugs directly after the top-level domain.)
Instead, we recommend organizing folders by the function they serve on your site, e.g.:
It’s no secret that including your target keyword in your URL can help your page rank for that keyword. With that in mind:
Here’s how that happens:
With that in mind, URL folder paths, in particular, should be kept as simple as possible.
Keyword stuffing your URLs will not make any modern algorithm happy, and your search engine results will suffer accordingly!
"SEO best practices for URLs" are one of the first things someone will discover when they begin to explore search engine optimization, given that URLs are a ranking factor. It is a very simple idea, but it’s easy to go down a rabbit hole and create lots of unintended complications for yourself.
The good news is that once your URL issues have been resolved, you can create 301 redirects from the old URL versions to the new ones. This ensures that any pages pointing to the old URLs will resolve permanently to the new, optimized versions.
And fortunately, today most CMSs (Content Management Systems) are built with simple, automated URL structures, so getting URLs "right" can be as simple as including the right keywords in the right places.
Do you need help creating the best URL structure to improve your brand's ranking signals in Google search? Contact us today!