URL Slug Generator
A readable, stable, lowercase slug — with the words that do not belong in a URL removed.
What a slug is for
A slug is the human-readable tail of a URL. /blog/best-noise-cancelling-headphones-2026/ tells a reader and a crawler what the page is about before either one fetches it, and it is the fragment people read when a link is pasted into a chat window. Its job is comprehension and stability, not keyword stuffing.
The rules that matter, in order
- Lowercase everything. URLs are compared case-sensitively on many servers, so
/Aboutand/aboutcan be two different pages, one of which 404s. - Separate words with hyphens. Google treats
-as a word separator;_is not reliably treated the same way, sonoise_cancellingmay be read as one token. - Strip accents rather than encoding them.
cafébecomescafe, notcaf%C3%A9. Percent-triplets in a slug are unreadable and double-encoded when someone copies the URL. - Drop punctuation entirely. Apostrophes, commas and quotes carry no meaning to a parser and get escaped inconsistently.
- Remove stop words —
a,an,the,of,for— when the slug is long. Keep them when removing one makes the phrase ambiguous. - Keep it short. Five meaningful words is a good ceiling; long slugs get truncated in search results.
Why slugs should never change
A slug is a permanent identifier in practice. Inbound links, shares, bookmarks and external citations all point at the exact string. Changing it breaks every one of them unless you serve a 301 redirect from the old path. The rule that saves the most pain: choose the slug from the topic, not from the working title. how-to-fix-a-leaky-tap survives a headline rewrite; new-post-3 never had a chance.
Transliteration and non-Latin scripts
- Latin alphabets with diacritics map cleanly:
ñ→n,ö→o,ł→l,ß→ss. - Cyrillic and Greek have established romanisations, though the choice between them affects the result.
- CJK titles cannot be transliterated into meaningful slugs. Either keep the characters — modern browsers render and index them, though they must be percent-encoded on the wire — or use a short English identifier plus a numeric suffix for uniqueness.
- Mixed scripts in one slug are legal but read badly. Pick one convention per site.
Do not stuff keywords into a slug. Search engines read the slug as a weak signal, and a reader sees an obviously machine-generated address. One clear phrase beats six keywords separated by hyphens.
How to use it
- Paste your title or phrase.
- Choose whether to strip accents, remove stop words, and cap the word count.
- Copy the slug.
- Attach it to a path that will not change, and redirect old paths with a 301 if you ever do.
Worth knowing
- Google treats hyphens as word separators; underscores are handled less reliably.
- Accented characters should be transliterated, not percent-encoded, inside a slug.
- Search results truncate long URLs, so five words is a practical ceiling.
- Changing a live slug requires a 301 redirect from the old path.
Limitations
- No slug can guarantee uniqueness — a suffix or a directory is still needed for collisions.
- CJK slugs must be percent-encoded on the wire and read poorly when copied.
- Stop-word removal can change meaning when a stop word carries the contrast in a phrase.
- Romanisation conventions differ between languages, so results are conventional rather than canonical.
Frequently asked questions
Should I use hyphens or underscores in a URL?
- as a word boundary; _ is often read as part of a single token, so the words in noise_cancelling may not be recognised individually.