URL Slug

17 Jan., 2023

Search Engine optimization

URL Slug

What is a URL slug?

A URL slug is the part of the URL that follows the forward slash ("/") after the domain name or subfolder.

The term "slug" is used to refer to parts of a URL that consist of one or more words and can be read by both search engines and users. Slugs are typically located at the end of a URL and uniquely direct users to a digital resource by referencing it with a specific URL structure.

A URL slug consists of natural language terms that clearly describe the website's content. Depending on how URL slugs are generated, the result is user-friendly URLs (also called clean URLs, semantic URLs, or pretty URLs) and meaningful permalinks.

Good URL slugs are usually in an easily readable format, which helps readers and search engines better understand the page's content. However, slugs can also contain numbers, dates, author names, and more, depending on the website's permalink structure.

Thanks to WordPress, where a slug is clearly visible and easily editable, the term has become widespread among webmasters and SEOs.

  • https://www.mikgroup.ch/blog/keyword-suche/

In the example above, keyword-search is the URL slug.

Why is a URL slug important for SEO?

A URL slug is often considered a good place to include a page's target (or main) keyword. After all, Google Search Advocate John Mueller has confirmed that words in a URL are a ranking factor. However, he also emphasized that it is a "very, very minor" factor for search engines. SEO This is a tool that primarily serves to evaluate the page before Google accesses it.

In one of his tweets, Mueller also said:

Why is a URL slug important for SEO?

Mit anderen Worten:

While keyword use in URLs is a ranking factor, we shouldn't overestimate its impact on ranking and SEO. Nevertheless, it can be beneficial to include a page's target keyword in a URL slug, especially considering user experience (UX), which is closely linked to SEO.

Let's take a look at these two examples:

  • https://webseite.ch/blog/wanderung/rigi
  • https://webseite.ch/blog/4682

While the first example provides clear information about the content of the article, the second example is merely a string of numbers that offer no added value for the customer.

If someone only sees these two URLs, they are much more likely to click on the first one (regardless of the actual content of the two pages). Therefore, a URL slug should provide a concise description of a page. A good way to do this is by using the target keyword.

Best practices for URL slugs

Let's take a look at some of the best practices and tips on how to create good URL slugs.

Best practices for URL slugs

Be descriptive

As mentioned earlier, the primary role of URL slugs is to make URLs more user-friendly. Therefore, they should describe the content of a page.

  • Good URL slug: /best-handmixer
  • Bad URL slug: /7923

Using the target keyword is a great way to achieve this. Why? Because it's usually a precise, yet very short, description of what the page is about. Which brings us to the next tip…

Concise and easy to read

A good URL slug shouldn't be too long. Long URLs are harder to read and/or remember. Try to use fewer than five words in your slug.

Good URL slug: /yoga-exercises

Bad URL slug: /the-best-yoga-exercises-for-all-muscle-parts-of-the-body

Separating words

How you hyphenate (or don't hyphenate) words affects the readability of a URL slug. Hyphenating words in the slug helps users understand the URL more easily.

  • Good URL slogan: /best-travel-tips
  • Bad URL slug: /best-travel-tips

Use hyphens, not underscores.

The best method is to use hyphens to separate words in URLs. Other separators (such as underscores) may not be interpreted correctly by search engines.

  • Good URL slogan: /delicious-banana-bread
  • Bad URL slogan: /delicious_banana_bread

Use lowercase letters

Since URLs are often case-sensitive, it is best to use lowercase letters to avoid problems and make manual URL entry easier.

  • Good URL slogan: /stadt-bern
  • Bad URL slogan: /City-Bern

Avoid special characters

Google Search Central recommends avoiding non-ASCII (American Standard Code for Information Interchange) characters, such as special characters from some languages ​​or emojis.

  • Good URL slogan: /emoji-meanings
  • Bad URL slogan: /😊🚀

Future-proof

It is best to avoid numbers that are likely to change in the future, such as the number of tips or ideas, or the year of publication.

  • Good URL slug: /how-to-write-url-slugs
  • Bad URL slug: /10-tips-for-writing-url-slugs-in-2022

Note: If you need to change the URL slug, make sure you redirect the old URL to the new one.

 URL

FAQs

Are website slugs important for SEO?

Yes, URL slugs are important for search engine optimization and therefore for search engine rankings. They are a key element of user experience. And UX and SEO are closely linked. The words used in URLs are also a very minor ranking factor.

What is the difference between a URL slug and a URL?

The URL is the complete web address of a page, while the URL slug is only the last part of the URL, which serves as an identifier for the page.

  • URL: https://www.apple.com/shop/iphone/12
  • URL slug: /iphone-12

What happens if you change the URL slug?

Once the URL structure is changed, the entire URL of a page is changed. This means that the page can no longer be accessed via the old URL.

Every time you change the URL structure, it is recommended to set up a 301 redirect from the old URL to the new one.

This prevents users from landing on a 404 error page. Furthermore, you may lose traffic and link equity from links pointing to the old URL.

Similar articles:

Request free SEO consultation

Enter your details and we will contact you 📅

    Increase your traffic!

    Analyze your website now ➜

    Switzerland Flag