Slug Generator — Free Online Tool on Toolpile
Every tool you need, one place
PDF, Image, AI, Dev, and Business tools — free, private, no signup.
Toolpile uses cookies for analytics and ads. The tools themselves keep your files in the browser — that doesn't change. Read the full policy
PDF, Image, AI, Dev, and Business tools — free, private, no signup.
About Slug Generator
A slug is the URL-safe version of a title — the part after the last `/` in `example.com/blog/how-to-bake-bread`. Getting it right matters for SEO (Google reads slugs as relevance signals), for sharing (clean slugs are easier to paste into Slack and read aloud), and for stability (a slug that changes silently breaks every external link). This tool generates slugs; what follows is the rules that turn a title into a slug that ages well.
A clean slug is **lowercase, hyphen-separated, ASCII-only, and stripped of stop words**. So "How To Bake The Best Bread" becomes `how-to-bake-best-bread` (or just `bake-best-bread` if you're aggressive about removing common words). Capitals get lowered (`How` → `how`), spaces become hyphens, special characters drop, accented characters get transliterated (`café` → `cafe`).
Hyphens (`-`), not underscores (`_`). Google has confirmed they treat hyphens as word separators (so `bake-bread` reads as two words) and underscores as joiners (so `bake_bread` reads as one compound word). For SEO, hyphens win every time.
Length: aim for 3-5 words. Long slugs like `how-to-bake-the-absolute-best-sourdough-bread-at-home-in-2026` work but get truncated in search results, social media previews, and email subject lines. Short slugs (`bake-bread`) are stable but miss keyword opportunities. The 3-5 word target hits the sweet spot — descriptive enough to convey topic, short enough to render fully.
Most CMS slug generators handle the basics; the differences come from how they handle edge cases — accents, punctuation in unusual scripts, very long input, and uniqueness (what happens if two posts produce the same slug). This tool covers the standard transforms; for production publishing, you also need a uniqueness strategy (auto-append `-2`, `-3` for collisions) which the CMS handles, not the generator.
Stop words are common words that carry little semantic weight — "the", "a", "an", "is", "of", "and", "to", "how", "why", "in", "for". Removing them shortens slugs and concentrates keywords. "How to Bake Bread" → `bake-bread` instead of `how-to-bake-bread`.
The trade: short slugs lose long-tail SEO keywords. Someone searching "how to bake bread" matches `how-to-bake-bread` exactly; `bake-bread` is a partial match. Google has said for years that slug exact-match doesn't dominate ranking — content quality matters more — but keeping question-style words ("how", "why", "what") in slugs that target question searches is a small, free advantage.
Aggressive stripping (this tool's default "SEO mode") removes `how`, `why`, `what`, `the`, `a`, `an`, `to`, `of`, `is`, `are`. Conservative stripping (this tool's "basic mode") only removes punctuation and lowercases. Pick aggressive for evergreen articles where the slug needs to be short; conservative for question-targeting content where you want the exact phrase preserved.
Brand names: keep them. "Top 10 Apple Products" → `top-10-apple-products` keeps `apple` because that's the searchable term. Generic stop-word stripping shouldn't touch brand and product names; this tool's stop-word list excludes the obvious common nouns, not anything that could be a brand.
Slugs need to be URL-safe ASCII. Most modern URLs technically support Unicode (`example.com/café` is legal), but in practice: (1) email and chat apps mangle non-ASCII URLs into ugly Punycode (`xn--caf-dma`), (2) some legacy systems break, (3) reading aloud or typing the URL is harder. Transliterate to ASCII for safety.
**Latin-based diacritics** (é, ñ, ü, å, ø) transliterate cleanly: `é → e`, `ñ → n`, `ü → u` (or `ue` in German convention), `å → a` (or `aa` in Danish/Norwegian convention), `ø → o`. The default this tool uses is the simplest single-letter mapping; for German content where `ü → ue` is convention, switch the mode.
**Cyrillic, Greek, Arabic, Hebrew** transliterate via romanisation tables — Cyrillic Москва → `moskva`, Greek Αθήνα → `athina`, Arabic القاهرة → `al-qahirah`. The romanisation isn't always one-to-one (different schemes give different results), and this tool uses the most common ASCII transliteration. For language-specific schemes (BGN/PCGN, ALA-LC, ISO 9), use a dedicated transliteration tool.
**CJK (Chinese, Japanese, Korean)** is the hard case. Hanzi/Kanji/Hanja have multiple readings and no single ASCII transliteration. The two reasonable approaches: (1) use a romanisation system (Pinyin for Chinese, Romaji for Japanese, Revised Romanisation for Korean) — `北京` → `beijing`, `東京` → `tokyo`. (2) keep the original characters and accept Punycode in the URL — works on modern browsers but not in plain-text contexts. Most Chinese/Japanese/Korean publishers go with option 1 for SEO and shareability.
Should I include the date or year in slugs?
Generally no for evergreen content — `bake-best-bread` ages better than `bake-best-bread-2026` because the year-tagged URL needs an annual update or it ages out. For news and explicitly time-bound content ("2026 tax brackets", "WWDC 2026 announcements"), include the year — it's accurate and searchable. Most CMS platforms put the date in a separate URL segment (`/2026/04/bake-bread`) which gives you both options.
Can I change a slug after publishing?
Yes, but every external link to the old slug breaks unless you redirect. Modern CMS platforms (WordPress, Ghost, Webflow) auto-create 301 redirects when you change a slug — link equity and SEO ranking transfer to the new URL. Static site generators usually don't auto-redirect; you have to add the rule manually. Always check redirect handling before changing live slugs.
What's the maximum slug length?
Practically: keep slugs under 60 characters. Google truncates URLs in search results around 70 characters; social media link previews truncate sooner. Technically: HTTP and DNS allow URLs up to ~2,000 characters, but no human or system benefits from a 200-character slug. Anything past 60 characters is bookkeeping, not SEO.
Should slugs match the page title exactly?
Close, not exact. Strip stop words, lowercase, hyphenate. The slug should reflect the topic; the H1 heading on the page can be more conversational. "How to Bake the Best Sourdough Bread at Home" (H1) → `bake-best-sourdough-bread` (slug). Reading the slug should give a clean topic preview without reproducing the headline verbatim.
Is there a difference between slugs and URL paths?
A path is the full string after the domain (`/blog/2026/bake-bread`); a slug is one segment of that path (`bake-bread`). Most CMS platforms ask for the slug and assemble the path from `/<category>/<year>/<slug>` or similar. The conventions in this article apply to slugs specifically; full paths are designed at the site-architecture level.