The ultimate guide to an SEO Friendly URL structure

July 26, 2021
SEO Fundamentals

SEO friendly URLs are URLs that work well for both visitors and search engines. URLs in general describe the location of a document or page for visitors and search engines. Well chosen URLs are vital to good SEO performance. When it comes to URLs, follow these best practices:

  • Keep your URLs descriptive and readable;
  • Keep your URLs brief;
  • Keep your URL structure consistent.

Apply the KISS principle: "Keep it simple, stupid".

What is a URL?

URL stands for Uniform Resource Locator. URLs describe the location of a document or page for visitors and search engines.

Your preferred way of structuring the URLs on your website is called your URL structure.

Why it’s important for SEO

Setting a clear URL structure is important for a website's Information Architecture which defines, among other things, how your content is made accessible to visitors and search engines. It defines the relationships among pages and what URLs and directories to use.

Having an Information Architecture provides everyone clarity about what URLs to use and forces you to think ahead about your URLs.

But what preferences can you choose from? In order to answer that question, let's look at the anatomy of a URL.

The anatomy of a URL

The anatomy of a URL

Let's break down https://www.example.com/about/team?member=kevin#experience:

  • Protocol: https://
  • Subdomain: www
  • Domain: example.com
  • Directory: about
  • Page: team
  • Parameters: ?member=kevin
  • Fragment: #experience
Rule over your URLs!

Quickly audit the setup of your URLs. Discover what can be improved with ContentKing.

Protocol: HTTP or HTTPs

Choose whether or not to serve your URLs over a secure connection, using the HTTPS protocol.

Best practice
It's recommended to serve your URLs over HTTPS. If you're still making the switch from HTTP to HTTPS, make sure to 301-redirect requests for the HTTP variant of URLs to the HTTPS variant of URLs. And vice versa.

Subdomain or no subdomain

Choose whether or not you'll use the www subdomain.

Best practice
If you choose to use www, make sure to 301-redirect requests for URLs without the www subdomain to the URL variant with www. And vice versa.

Domain name

The domain name consists of a name and an extension: a Top Level Domain (TLD).

Best practice
If you're in the position to choose a new domain, choose one that's short and easy to remember.

Directories in URLs

While it's important to keep URLs as short as possible, it's also recommended to group related URLs together on your website using directories. Directories can become useful for websites with even as few as 50 pages.

Are you having trouble organizing your URLs using only one level of directories because of the size of your website? You can use sub-directories if that helps bring back order but keep the amount of directories per URL as low as possible.

Best practice
Choose short directory names, to keep your URLs as short as possible.

Here's an example of good directory usage:

https://www.example.com/men/socks/tommy-hilfiger/

and here's an example of bad usage:

https://www.example.com/men-fashion/socks-for-men/tommy-hilfiger-men/

Pages (or also called slugs)

Pages, also called slugs, are used to identify and describe a unique page on a website. This is the part of the URL that changes for each individual page.

Parameters in URLs

Parameters in URLs are often used to pass on data. As mentioned earlier, avoid using parameters in URLs as much as you can. These parameters don't provide context to visitors or to Google.

Fragments in URLs to jump to a section

Fragments are used in URLs to be able to jump to a specific section within a page.

An example of a URL with a fragment: https://www.example.com/about/team/#king-kevin

# is the fragment and king-kevin is the fragment identifier in this example.

Setting your URL Structure

When setting your URL structure, it's important to keep the following in mind.

Casing

Illustration for case sensitivity in URLs

URLs are case-sensitive, meaning that https://example.com/url-a/ and https://example.com/url-A/ are seen as different URLs. Stick to URLs with lowercase characters only.

When creating links, it's easy to make a typo which causes both versions of the URL to get indexed. This is duplicate content and should be avoided.

Best practice
When a URL with uppercase characters is requested, it should 301-redirect to the version of the URL that's in all lowercase characters, the canonical version. If that's not possible, make sure to implement a canonical URL to the canonical version.

To slash, or not to slash?

Illustration of usaging slashes in URLs

Choose whether or not you'll use a / at the end of each URL. If you choose to use it, make sure that URLs without the / at the end get 301-redirected to the URL variant with the / at the end. And vice versa.

Should I use an extension, or not?

You can choose to give URLs an extension, such as for instance .php, .html or .aspx. However, it's recommended to avoid extensions in URLs because otherwise:

  • It makes URLs longer.
  • It makes for more typos when people adjust a URL directly in their address bar.
  • It makes migrating to a different platform more complex and riskier because you don't have to migrate URLs, as they don't necessarily change.
Check if your URL structure is set up correctly

Get a second pair of eyes. Quickly check your site's URLs with ContentKing and see what can be improved.

Best practices for SEO friendly URLs

Google writes (opens in a new tab): "A site's URL structure should be as simple as possible. Consider organizing your content so that URLs are constructed logically and in a manner that is most intelligible to humans."

That makes sense, but how do you go about that?

We've broken SEO friendly URLs down to these properties:

  • descriptive and readable
  • short
  • consistent

Examples of good and bad URLs

Here's an example of a good URL:

https://www.example.com/iphone-8

and here's an example of a bad URL:

https://www.example.com/index.php?productID=83671

Descriptive and readable URLs

A potential visitor should get an idea of a page's content just by looking at the URL. They will be much more inclined to click on a Google search result with a descriptive and readable URL. To this end, keep the following in mind:

  • Keywords in URLs: Include one or two important keywords in the URL. This helps both search engines and visitors understand what they can expect at the URL.
  • Don't stuff URLs full of keywords: Stuffing URLs full of keywords hurts readability and is a clear sign of over-optimization, so avoid doing this. It doesn't add any value, and it may even hurt your SEO performance.
  • Avoid stopwords in URLs: Avoid stopwords ("grammar" words that don't say much) in URLs. They don't add value to URLs; they only make a URL less readable and longer.

Here's an example of a good URL:

https://www.example.com/blog/best-advice-for-copywriter/

and here's an example of a bad URL:

https://www.example.com/blog/the-best-advice-for-a-copywriter/

Keep URLs short

Visitors and search engines both prefer short URLs, so keep URLs short. Use as few directories as possible, and if you can use just one, do so.

But short URLs are a technique, not the goal. Your goal is readable and logical URLs.

Keep URLs consistent

You need to choose one preferred way to build up the URLs on your website and stick to it.

Imagine having put in blood, sweat, and tears and finally seeing your organic traffic grow. In this moment of triumph, you don't want to be changing directories or pages in URLs, as that requires implementing redirects to forward visitors and search engines to new URLs. So think ahead when you're choosing URLs.

  • Separate words using hyphens: Separate words in URLs using hyphens (-). Even though search engines support underscores (_) as word separators nowadays, your readers' eyes prefer hyphens.
  • Future proof URLs by removing dates: Choose a generic URL that can be re-used year after year. Chances are you'll be getting links from other websites to that page and you want to harness the authority that those links pass on every year. So keep things stable!

Relative URLs and Absolute URLs

Relative URLs are URLs that don't reference the protocol, subdomain, and domain. For example: /about/team/

Absolute URLs are URLs that reference the full URL, including protocol, subdomain, and domain. For example: https://www.example.com/about/team/

When linking to pages within your own website, it's recommended to use relative URLs, for two reasons:

  1. When you change domain names, you don't have to change all your links. They'll keep working.
  2. If you're using a test environment with the same content as your production environment, relative URLs ensure the test environment is fully functioning.

Please note, however, that it's recommended to use absolute URLs in canonical URLs and hreflang.

Conclusion

URLs play an important role in your SEO performance. Choose URLs that are descriptive, readable, and short. Be consistent with the URLs in your website, and you'll reap benefits.

Frequently Asked Questions

ContentKing Academy Content Team

Jessica is a content marketer for ContentKing. Her days are spent writing marketing content, cycling around canals in Amsterdam and attempting to master the Dutch language.

Steven is ContentKing's VP of Community. This means he's involved in everything community and content marketing related. Right where he wants to be. He gets a huge kick out of letting websites rank and loves to talk SEO, content marketing and growth.