What a good slug looks like
The slug is the part of a URL that names one page. In https://writepadpro.com/blog/how-to-write-url-slugs, the slug is how-to-write-url-slugs. A good slug is short, lowercase, made of real words separated by hyphens, describes the page, and never changes after the page is published.
This guide covers what Google's own documentation says about URLs, practical rules for writing slugs, a before-and-after table generated with the URL Slug Generator, how accents and non-Latin scripts are handled, and what to do if you must change a slug that is already live.
What Google's documentation says
Google Search Central publishes URL structure best practices (page last updated 2025-12-10; we checked it on 2026-10-14). The points that matter for slugs:
- Readable words over IDs. Google recommends readable words rather than long ID numbers when possible.
/blog/how-to-write-url-slugstells a reader and a search engine more than/blog/?p=4721. - Hyphens, not underscores. The guide recommends hyphens (-) to separate words and says it does not recommend underscores (_).
- Case matters. Google says its URL handling is case sensitive, so
/Blog/My-Postand/blog/my-postare different URLs to it. Pick one case; lowercase is the easy choice. WritePadPro itself redirects any URL path with capital letters to its lowercase version for this reason. - Non-ASCII characters. Characters outside the ASCII range should be percent-encoded in links. Browsers and most content management systems do this for you.
- Simple structure, few parameters. Google asks for a simple, logical URL structure and as few parameters as possible.
Note what the guide does not do: it does not set a maximum length or a number of words. The length advice below is our own editorial recommendation, not a Google rule.
Eight rules for writing slugs
- Describe the topic in three to six words. Start from the main phrase someone would use to find the page, not from the full headline.
- Use lowercase letters, digits and hyphens only. No spaces, no underscores, no punctuation, no emoji.
- Drop words that add nothing, such as "the", "a" or "of", but keep small words that carry meaning. "how-to" reads better than "how" alone.
- Leave out details that will change. A year, a count ("10 tips") or a version number in the slug ages badly when you update the article. Keep them in the title instead.
- Keep the brand out. Your domain already names the site.
- Do not stuff keywords. One clear phrase beats a string of near-synonyms.
- Make every slug unique within its folder, and be consistent across the site: same separator, same case.
- Decide once. Treat a published slug as permanent. Changing it later means a redirect (see the last section).
Slug patterns by page type
The same rules apply everywhere, but each kind of page has its own typical mistake. These are our recommendations:
| Page type | Avoid | Prefer | Why |
|---|---|---|---|
| Blog article | /blog/2026/11/the-ultimate-guide-to-writing-better-url-slugs-in-2026 | /blog/how-to-write-url-slugs | Dates in the path and in the slug make an evergreen article look old. |
| Product | /product?id=88213&color=blue | /shop/merino-wool-socks | Readable words instead of an ID; variants such as color can stay as options on the page. |
| Category | /category/cat-12 | /shop/socks | A category slug is often reused in every product URL below it, so keep it to one or two words. |
| Landing page | /lp/spring-promo-v3-final | /spring-sale | Internal version labels leak into a public address that people share. |
| Translated page | /de/how-to-write-url-slugs | a slug in the page's own language | Readers of the German page should recognize the words in its URL. |
Before and after: real titles, real slugs
The middle columns come straight from the URL Slug Generator; the last column is the slug we would publish, usually obtained by trimming the title before generating it.
| Title | Default slug | With an option | Slug to publish |
|---|---|---|---|
| How to Write URL Slugs: 9 Rules (With Examples) | how-to-write-url-slugs-9-rules-with-examples | Remove stop words: how-write-url-slugs-9-rules-examples | how-to-write-url-slugs |
| The 10 Best Coffee Shops in São Paulo for 2026 | the-10-best-coffee-shops-in-sao-paulo-for-2026 | Remove stop words and numbers: best-coffee-shops-sao-paulo | best-coffee-shops-sao-paulo |
| Q&A: Why 90% of Résumés Fail | q-and-a-why-90-percent-of-resumes-fail | Symbols not spelled out: q-a-why-90-of-resumes-fail | why-resumes-fail |
| O’Brien’s Guide to C++ & C# | obriens-guide-to-c-plus-plus-and-c | (the # is dropped, so C# became "c") | obriens-guide-to-cpp-and-csharp |
| Müller & Söhne: Straße der Einheit | muller-and-sohne-strasse-der-einheit | German rules: mueller-and-soehne-strasse-der-einheit | German rules, for a German audience |
| Best Running Shoes for Flat Feet in 2026 — Tested and Reviewed by Our Team | 72 characters | Maximum length 50: best-running-shoes-for-flat-feet-in-2026-tested | best-running-shoes-flat-feet |
| 🔥 Hot Deals 🔥 | hot-deals | — | hot-deals |
Two lessons from the table. First, a tool can clean characters but cannot judge meaning: "C#" losing its "#" is correct slug behavior and still the wrong result, so read every slug before publishing. Second, the maximum length option cuts at a word boundary, which avoids half-words, but a cut-off slug that ends in "tested" is rarely the best slug; shortening the title gives a better one.
How the generator builds a slug
Knowing the exact steps helps you predict the output:
- Clean up. HTML entities are decoded (
&becomes &), and invisible zero-width characters and soft hyphens are removed. - Spell out symbols (on by default): & becomes "and", % "percent", + "plus" and @ "at".
- Join contractions. Apostrophes inside words disappear instead of splitting them: "Don’t Stop Believin’" becomes
dont-stop-believin, not don-t-stop. - Lowercase (on by default).
- Transliterate (on by default): accents are removed (é → e, ñ → n, every Vietnamese tone mark), letters without an unaccented form are spelled out (ß → ss, æ → ae, ø → o, ł → l, þ → th), and Cyrillic and Greek are converted to Latin letters.
- Split into words. Only letters and digits survive; every run of punctuation, spaces, symbols or emoji becomes one separator. That is why a messy title such as "Lots of spaces --- and dashes__" becomes
lots-of-spaces-and-dashes, with no doubled hyphens and no trailing separator. - Optional filters. Remove stop words, remove stand-alone numbers, or drop non-Latin words.
- Join and trim. Words are joined with a hyphen (or an underscore if you choose it), and an optional maximum length trims at the last whole word that fits.
The stop-word filter uses a short list of 28 English words: a, an, the, and, or, but, nor, of, in, on, at, to, for, from, by, with, as, into, onto, upon, is, are, was, were, be, been, being and am. It never removes every word: "Of and To" stays of-and-to. It can still surprise you, though. "To Be or Not to Be" with stop words removed becomes not, which is why the option is off by default.
For a whole list of titles, put one per line. Each line gets its own slug, a table shows the length of each, and "Make duplicates unique" adds -2, -3 and so on: "Contact Us", "Contact us" and "Contact US!" become contact-us, contact-us-2 and contact-us-3. You can copy the slugs, download them as a text file, or download a CSV with each title next to its slug for a CMS import. The status line warns when a slug is longer than 75 characters.
Accents, other alphabets and non-Latin slugs
Transliteration rules differ by language, and the generator lets you pick:
- Standard removes accents: "Smørrebrød på Ærø" becomes
smorrebrod-pa-aero. - Danish / Norwegian spells the letters out:
smoerrebroed-paa-aeroe. - German gives ä → ae, ö → oe and ü → ue, as in the Müller example above.
- Serbian / Croatian gives đ → dj: "Sergej Đoković" becomes
sergej-djokovicinstead of sergej-dokovic. - Ukrainian follows the national system: "Київ і Харків" becomes
kyiv-i-kharkiv, where the Russian-style default gives kiyiv-i-kharkiv. - Bulgarian follows the Streamlined System.
Greek is transliterated too ("Αθήνα" becomes athina). Scripts without a transliteration table, such as Chinese, Japanese, Arabic or Hindi, are kept as they are while "Keep non-Latin letters" is ticked. A Japanese title such as 東京の天気 stays a five-character slug, and the preview shows that browsers send it percent-encoded as 45 characters (%E6%9D%B1%E4%BA%AC%E3%81%AE%E5%A4%A9%E6%B0%97). Untick the option and only Latin letters and digits remain, so that title produces an empty slug and the tool tells you so.
Which should you use? For a site written in that language, a slug in the same script is readable for your audience and is supported by modern browsers. For a mostly English site, a transliterated or translated slug is easier to type and share. To see how any URL is encoded, use the URL Encoder and our URL encoding guide.
Slugs, titles and meta descriptions work together
The slug is one of three short texts a searcher sees for your page, next to the title and the description. Write the title first, derive the slug from its core phrase, then write a description that delivers what the title promises. The Meta Tag Generator helps with the last two, and our meta tags guide explains the details. For a full pre-publish routine, see the 15-point blog SEO checklist.
Changing a slug that is already published
Every link, bookmark and search result points at the old address. Change it only for a real reason, such as a slug that is wrong, misleading or contains an error, and never just to squeeze in a keyword.
If you do change it, redirect the old URL. Google's documentation on redirects and Google Search (last updated 2026-04-14; checked 2026-10-14) explains the difference: a permanent redirect (HTTP 301 or 308) is used as a signal that the target should be the canonical URL, while temporary redirects (302, 303, 307) are not. Google recommends a permanent server-side redirect whenever possible, and only when you are sure it will not be reverted.
A clean slug change, step by step:
- Pick the new slug and publish the page under it.
- Add a permanent server-side redirect from the old path to the new one.
- Update your own internal links, menus and sitemap so they point at the new URL directly instead of through the redirect.
- If the page moves again later, point the oldest URL straight at the newest one rather than building a chain of redirects.
- Check the result:
curl -I https://example.com/blog/old-slugshould answer with a 301 status and a Location header naming the new URL.
Two common ways to write the redirect:
# Apache (.htaccess, mod_alias)
Redirect 301 /blog/old-slug /blog/new-slug
# Nginx (inside the server block)
location = /blog/old-slug { return 301 /blog/new-slug; }Your hosting panel or CMS may offer a redirect screen that does the same thing without editing files. Whatever you use, keep the redirect in place for as long as the old address might still be linked from somewhere.
Slug checklist
- Three to six words that name the topic.
- Lowercase, hyphens between words, no punctuation or emoji.
- No year, count or version that will change.
- Read it once: did a symbol such as # or + vanish and change the meaning?
- Unique within its folder.
- Never changed after publishing without a 301 redirect.
Paste your next title into the URL Slug Generator, compare the default with the stop-word and length options, and keep the shortest slug that still says what the page is about.