Skip to main content

What is a URL Slug?

Glossary image
URL identifier permalink slug

A URL slug is the human-readable portion of a web address that identifies a specific page, appearing at the end of the URL after the domain name and any directory structure. For example, in the URL https://example.com/blog/what-is-a-url-slug, the slug is what-is-a-url-slug. Slugs are typically written in lowercase letters, with words separated by hyphens rather than spaces or underscores.

The term "slug" originates from the publishing and newspaper industry, where it referred to a short internal name given to an article in progress. On the web, the concept carries a similar meaning: a concise, descriptive label that identifies a piece of content. Slugs are sometimes also called URL identifiers or simply referred to as part of the permalink structure of a page.

Why URL Slugs Matter for SEO

Search engines read the words contained in a URL as a signal about the content of the page. A well-constructed slug that includes a target keyword - such as url-slug rather than page-1 or p=482 - can contribute positively to a page's relevance for that term in search results. While the impact of URL keywords is considered a minor ranking factor compared to content quality or backlinks, a descriptive slug also improves click-through rates, since users can often infer what a page is about simply by reading the address in search results or when hovering over a link.

Beyond search engines, clean slugs improve the overall usability of a website. A URL like /services/web-design is far easier to share, remember, and type correctly than one containing random strings of numbers or query parameters. This clarity benefits both human visitors and automated tools that crawl and index web content.

How to Write a Good URL Slug

Effective slugs are short, descriptive, and free of unnecessary words. Common guidance involves removing stop words - articles and prepositions such as "a," "the," "of," and "in" - unless they are essential to the meaning. The slug should reflect the primary topic of the page and, where appropriate, include the main keyword that the page targets.

Hyphens are the standard separator for words within a slug, as search engines treat them as word boundaries. Underscores, while technically valid, are historically treated differently by some search engines and are therefore less preferred. Spaces and special characters should always be avoided, as they either break URLs or get encoded into less readable sequences like %20.

Once a slug is set and a page begins to attract traffic or inbound links, changing it should be approached carefully. Any modification to a slug requires a 301 redirect from the old URL to the new one to preserve accumulated link equity and avoid broken links for existing visitors.

Have a question?

Get in touch if you'd like to learn more about this topic.

Contact Us