What is a URL slug, and what makes a good one

Three to five words, lowercase, hyphens, no dates. And why changing it later costs you traffic.

The slug is the human-readable part of a URL that identifies one page: in textfizz.com/blog/what-is-a-url-slug/ the slug is what-is-a-url-slug. A good slug is lowercase, uses hyphens between words, contains 3 to 5 meaningful words, and describes the page well enough to be understood on its own in a chat message. Once published it should not change.

Slug, path, permalink: what the words mean

In https://example.com/blog/2026/url-slug-guide?ref=news#step2:

Permalink is the WordPress word for the whole URL. Slugify is the verb for turning a title into a slug: lowercase it, strip punctuation, replace spaces with hyphens, collapse repeats. A slug generator does exactly those four steps.

The rules that actually matter

RuleGoodBad
Lowercase onlymeta-description-lengthMeta-Description-Length
Hyphens, not underscoresremove-duplicate-linesremove_duplicate_lines
3–5 meaningful wordsinstagram-caption-lengththe-complete-and-definitive-2026-guide-to-instagram-caption-length-for-marketers
No stop words that carry nothinghow-to-count-wordshow-to-count-the-words-in-a-document
No dates or numbers that expiremeta-description-lengthmeta-description-length-2026
No file extensions or IDspdf-line-breakspage.php?id=4821
ASCII where you cancafe-guidecaf%C3%A9-guide

On case: URLs are case sensitive after the domain on most servers. /About and /about can be two different pages on Linux and the same page on IIS. Staying lowercase removes the question entirely.

On underscores: Google has treated hyphens as word separators and underscores as word joiners for years, so url_slug can be read as one token. The practical impact is small, the cost of using hyphens is zero.

On folders: /blog/what-is-a-url-slug/ against /what-is-a-url-slug/. Depth costs nothing in ranking terms up to about three levels, and a section folder helps readers and analytics — you can filter every blog URL with one rule. What does hurt is a folder that duplicates the slug, as in /blog/blog-url-slug/, and folders that describe your internal structure rather than the content.

On length: there is no penalty for a long slug, but there is a readability cost. A slug that fits inside a search result without truncation is around 50 to 60 characters of path. Check it with a character counter if you are near that.

Non-Latin alphabets and accents

Three options, each with a real trade-off:

For accents specifically, strip them: cafe, not café. Nobody types the accent when they retype a URL.

Never change a published slug without a redirect

Changing a slug creates a new URL. The old one returns 404. Every link pointing at it — other sites, your own old posts, bookmarks, newsletter archives, a Slack message from 2024 — now goes nowhere, and the ranking history attached to that address does not automatically move to the new one.

If you must change it:

  1. Add a 301 redirect from the old slug to the new one before or at the moment of the change.
  2. Update internal links to point at the new URL directly — chained redirects are slow and lose a little at each hop.
  3. Update the sitemap and resubmit it.
  4. Keep the redirect permanently. There is no safe date to remove it.

Expect a dip for 2 to 6 weeks even when everything is done correctly. That is the price, which is why the answer is usually: leave the slug alone and change the title instead. A title and a slug do not have to match, and after a year of ranking they rarely do.

What usually goes wrong

Turning a title into a slug, in practice

Take the working title. Drop everything that is not a letter, digit or space. Lowercase it. Remove the articles and any word that could be deleted without changing what the page is about. Join with hyphens. Read it back — if you could not guess the page from the slug alone, it is wrong.

The Complete Guide to Removing Duplicate Rows in Excel (2026 Update) becomes remove-duplicate-rows-excel. Four words, no year, no punctuation, obvious.

For a batch, paste the titles one per line into a slug generator, then sort the output to spot near-identical slugs before they collide in the CMS.

Related tools

Title case vs sentence caseThree style guides, three different answers, and the four-letter rule that…How random is randomGood enough for a raffle, not good enough for a password. Here is the actual…PDF text breaksThe file has no paragraphs to give you. Here is what it does have, and how to…Meta description lengthWhy 160 characters is a rule of thumb and 920 pixels is the real limit.Title case converterCapitalises a headline properly — short words stay lowercase, unlike naive…Coin flipHeads or tails in one tap, with a running tally.LinkedIn counterLive counts against LinkedIn post, headline, about and comment limits.

See all text tools →

Frequently asked questions

What is a URL slug?

The readable segment of a URL that identifies a single page, usually the last part of the path. In example.com/blog/url-slug the slug is url-slug.

How long should a URL slug be?

Three to five meaningful words, roughly 30 to 60 characters. Long slugs are not penalised but become unreadable when shared as plain links.

Hyphens or underscores in URLs?

Hyphens. Search engines treat a hyphen as a word separator and an underscore as a joiner, so my_slug can be read as a single token.

Can I change a slug after publishing?

Only with a permanent 301 redirect from the old URL, plus updated internal links and sitemap. Expect a ranking dip of two to six weeks anyway.

Should the slug match the page title?

It should match the meaning, not the wording. Titles get rewritten over time; the slug should stay stable, so a shorter core phrase is better.

Are uppercase letters allowed in a slug?

Technically yes, but URLs are case sensitive on most servers, so /About and /about can become two pages. Stay lowercase.

Should I put the year in the slug?

No. You will update the article next year and the URL will contradict the content, or you will change the slug and lose the links.