When a competitor’s website is just one click away, you want to invest time and effort in creating an engaging user experience. Intuitive navigation is crucial for retaining your audience’s attention and keeping them on your site.

Content categorization is the first thing web specialists do when they start working on navigation. When you finish categorization and know what structure you want to use for your website, then it’s time to focus on creating Uniform Resource Locators (URLs). The URL structure is a core part of the website structure, and it has a direct impact on usability. The better URLs are designed, the easier it is for users and search engines to navigate your website.

In this article, we will explore some recommendations on how to create a more user-friendly URL structure.

Make your IA decisions before designing URL structure

Creating a URL structure before finalizing your site’s information architecture is one of the typical mistakes that product teams make. It’s like building a house without a solid foundation. Nobody can guarantee that the house will be sustainable. Following the same approach for web design will result in inconsistent site architecture. What makes things worse is that in many cases, it’s impossible to fix IA issues with a URL change alone. That’s why it’s always better to invest in user research and conduct a series of card sorting and tree testing sessions to figure out what categories work for your visitors.

Model your URL structure after the top players in your niche

Once you have your IA developed and tested, you can begin to create the URL structure.

Jakob’s Law of Internet User Experience states that users spend most of their time on other sites. It means that users prefer your website to work the same way as all the other sites they already know. In other words, it’s always better to leverage industry familiarity and use existing patterns rather than providing a unique solution. By doing that, you will create a familiar experience for your target audience. This rule works for most design decisions, including website structure. To achieve this similar experience, conduct competitor analysis, analyze and evaluate various URL structures that your competitors use and use the same structure on your website.

Try to reflect categories in your URL structure

Categorization is a foundational principle of information architecture and should be reflected in your site’s URL. Category pages are great for organizing content – whenever you want to add a new page, you add it to an existing category and link to it from that category page. Your URL structure should logically follow your categories:

https://example.com/category/subcategory/keyword-keyword

screenshot of Best Buy website showing the chronological order of the site structure to get to a specific product page.
Best Buy’s URL structure includes product categories in their URL. Image credit Best Buy.

Minimize link depth

Both site visitors and search engines look to the site architecture for clues as to what pages are most important. A key factor is how many clicks from the home page it takes to reach a page. A page that is only one click from the home page is important. A page that is five clicks away is not nearly as influential. Ideally, your important pages should be 2-3 clicks away from your homepage. Anything that is 4-5 clicks away will be seen as less important.

Functional URLs

The functional URL is the URL that users can modify to get to a different place. A page that has a URL /level1/level2/level3 implies that /level1/level2 will also exist as a real page. Thus, make sure your website structure is flexible enough to allow users to modify URLs and get valid web pages.

screenshot of Amazon's website showing two dogs on the screen with a 404 page, detailing how a product could not be found.
Not all URLs at Amazon.com are functional. When you try to modify the URL, you can end up on 404 pages. Image credit Amazon.

Short vs. long URLs

There are multiple ways you can create a URL structure. For example, when you design a website structure for an eCommerce website that sells shoes, you can have a subfolder-like structure (i.e. “/shoes/men/oxfords/”) or a flat structure where everything collapses on one level (i.e. “/shoes-men-oxfords”). Both variants have their pros and cons, but usually, the final decision about the structure is a question of shorter URL vs. longer URL.

When you select a URL structure, always strive to create shorter URLs. Shorter paths are generally better than longer because it’s much easier for site visitors to remember and type shorter URLs. However, if your site has many categories and sub-categories, then longer URLs may be more appropriate to reflect your site’s hierarchy. And, it’s easier to create functional URL’s using a sub-folder like structure.

Human-readable URLs

URLs are intended to improve the usability of a website by being immediately and intuitively meaningful to visitors. In other words, visitors should be able to read a URL the way they read regular sentences. It makes sense to have descriptive words in your URLs, such as the names of categories or individual products, and consider using dashes in your URLs. 

Uncleaned URL Clean URL
/products/gen1/cat212/123415 /shoes/woman/heels/escarpic
/shoeselsescapric /shoes-escarpic

Hyphens vs. underscores

It’s recommended to use hyphens (-) instead of underscores (_) in your URLs. The underscore can look like a space to the user, which results in a 404 page rather than the actual page the user wants to visit.

Do not include technical details in URLs

When websites use URLs with a filename of a server-side script, such as example.php, example.asp, it not only makes the URL look technical for visitors but also introduces problems when the team decides to change the underlying technology. If the underlying implementation is altered (i.e., the organization decides to switch from PHP to Python), such URLs would need to change along with it.

Also, avoid adding session IDs or user IDs in the URL. Many CMSs add session IDs to track individual users as they’re surfing a site. Although this works well for this purpose, this solution isn’t right for search engines because the search engines see each URL as a different page rather than variants of the same page. Instead of adding session IDs in the URL, consider using cookies. Check out Google’s Webmaster Guidelines for additional information.

Uncleaned URL Clean URL
https://example.com/index.php?page=page1-products https://example.com/products
https://example.com/products?uid=234324

Always have one unique URL per unique piece of content

Inconsistent navigation is one of the most common IA problems. On some websites, the same page has two different URLs, depending on how visitors got there. For example, the user will have URL A when they get to the page via the top-level navigation (i.e., a website’s main menu) and URL B when they come in via contextual navigation (i.e., links in text copy). Try to eliminate all cases where URLs are different for the same page.

Add relevant keywords in URLs

The user typically starts browsing by typing a query into a search engine. The URL can play a key factor in giving your content the ability to rank in those searches. It can be useful to have appropriate keywords in the URL (both for users and search engines). Keywords help to set expectations on what users are going to see on the page, even before they click the link. But make sure the keywords are logical. Don’t stuff keywords in the URL to get better search engine ranking because doing that will increase the risk of a Google penalty.

screenshot of Mr Porter website showing a men's jacket and the url structure of the product page.
Mr. Porter adds a product name into the URL. Image credit Mr. Porter.

Consistent URL structure

The process of content categorization should help you identify all possible scenarios of content organization. As soon as you finish the content organization, you need to create a navigation format. Ensure that the website’s navigation format follows a consistent pattern. Create a URL structure based on this information and pay special attention to the edge cases (when existing URL patterns don’t fit the structure). 

Find broken links and fix them

You should continuously check for broken links on your website. When links result in a 404 error, it plays against you both in terms of user experience and the search results. Broken links frustrate visitors and lead to a lower rating in search ranking. You can use, online tools like Brokenlinkcheck or Deadlinkchecker, to find broken links.

A note on changing URL and redirects

Even in a perfectly organized website, there is always a chance of moving content, and you need to undertake URL changes with care. There are two types of redirects you can use – 301 and 302. A 301 redirect means that the page has permanently moved to a new location. A 302 redirect means that the move is only temporary.

Test your URL structure

Design is an iterative process, and the development of your website structure is no exception. Once you have a hypothesis on how to design URLs, build a simple solution, and test it with your users. Integrate your findings into the next iteration of your URL structure and then try again.

Conclusion

Google offers simple, yet powerful advice on URL structure: “A site’s URL structure should be as simple as possible.” The KISS principle (“keep it simple, stupid”) applies to all design decisions, including the website structure. When your URL and site architecture are structured and logical, it becomes more useful to site visitors and search engine crawlers.