ToolBook
Support us on Ko-fi
Help us keep this free, forever

Slug & URL Generator

How to use the ToolBook Slug Generator

Paste a title or sentence and copy the URL-ready slug. Tweak separator, accent handling, and length live.

  1. Paste your title

    Drop the article title, page heading, or any phrase you want to turn into a URL slug.

  2. Pick your separator and options

    Default is hyphen + lowercase + transliterate accents — what Google likes best. Toggle stop-word removal to drop "the", "a", "of", and similar. Enable "Remove numbers" to strip year suffixes like "-2026".

  3. Set a max length

    Slide the cap to 60 characters by default. Going over 60 risks truncation in search results.

  4. Copy the slug or path

    Click "Copy slug" to copy the plain slug, or "Copy as /path" to copy it with a leading slash — ready to paste directly into a CMS path field.

  5. Use Bulk mode for multiple titles

    Enable "Bulk mode", paste one title per line, and get a numbered slug list. Use "Copy all" to grab every result at once.

Frequently asked questions

What is a URL slug?

A slug is the human-readable last segment of a URL — the part that comes after the final slash. For "https://toolbook.io/blog/how-to-write-good-slugs", the slug is "how-to-write-good-slugs". A good slug is short, lowercase, hyphen-separated, and made of words that match how people search.

Should I use hyphens or underscores in slugs?

Hyphens. Google explicitly treats hyphens as word separators and underscores as part of the word, so "my-post" is parsed as two words and "my_post" as one. Underscores are fine for code identifiers; for URLs, always use hyphens.

How long should a slug be?

Aim for 3–6 words and under 60 characters. Long slugs get truncated in search results, look spammy, and are harder to share. The truncation slider on this tool defaults to 60 because that is roughly where Google cuts the visible URL.

Should the slug match the page title exactly?

Close, but not exact. Drop articles ("the", "a"), prepositions ("of", "on"), and connector words ("and", "to") if the slug feels long. Keep the keywords. "How to write good URL slugs in 2026" becomes "write-good-url-slugs", not "how-to-write-good-url-slugs-in-2026".

How are accented characters handled?

When the "Transliterate accents" toggle is on, characters with diacritics are normalized to their ASCII equivalents — "café" becomes "cafe", "naïve" becomes "naive", "über" becomes "uber". This avoids percent-encoded URLs that look ugly when shared.

Should I change the slug after publishing?

Avoid it. Changing a slug breaks every existing link to the page. If you must change it, set up a 301 redirect from the old slug to the new one to preserve the SEO history.

What is a WordPress slug?

In WordPress, a slug is the URL-friendly version of a post or page title. WordPress auto-generates one when you type a title, but its version often includes stop words or is too long. Paste your title here, refine it, then paste the result into the WordPress slug field before publishing.

How does the tool handle special characters like & and $?

Special symbols are converted to their word equivalents before slugifying: & becomes "and", $ becomes "dollar", @ becomes "at", % becomes "percent", and # becomes "hash". This keeps slugs readable instead of producing raw percent-encoded characters like %26.

Can I generate slugs for multiple titles at once?

Yes. Enable "Bulk mode" and paste one title per line in the input area. The tool slugifies each line independently and shows all results in a numbered list — each with its own copy button. Use "Copy all" to grab every slug at once.

Does capitalisation matter for SEO in URL slugs?

Lowercase is the universal standard. Most web servers treat uppercase and lowercase URLs as different pages, which can create duplicate-content issues. Search engines canonicalise to lowercase, so always slug in lowercase to avoid accidental duplicates and redirect chains.

The complete URL slug field guide

Why hyphens beat underscores, how short is short enough, and the SEO mistakes that cost ranking.

What makes a good URL slug

A slug is the human-readable last segment of a URL — the bit after the final slash. For toolbook.io/blog/how-to-write-good-slugs, the slug is how-to-write-good-slugs. It is the first thing a search engine reads about a page, the most-shared visible part of the URL, and the part that travels with every link, tweet, and Slack message.

Three rules cover most cases. Keep it short. Keep it readable. Match the language people actually search.

Hyphens, not underscores

Google explicitly treats hyphens as word separators and underscores as part of the word. my-post parses as two words ("my" and "post"); my_post parses as one ("my_post"). For URLs you almost always want the search engine to see word boundaries, so hyphens win.

Underscores survive in code identifiers because programmers use them as separators where hyphens are illegal (you cannot name a variable my-post in Python). On the web, hyphens are the only right answer.

Length: aim for under 60 characters

Search results on desktop Google show roughly 70 characters of URL before truncating with an ellipsis. Mobile shows even less. The 60-character cap on this tool defaults to that ceiling because anything longer gets cut visibly in search results — losing exactly the keywords you fought to include.

A clean target is three to six words. Headlines often run twelve to fifteen words; trim aggressively. "How to write good URL slugs in 2026 — a complete guide" is a great article title; the slug should be write-good-url-slugs-2026 or even just good-url-slugs.

Drop the joining words

Articles ("a", "an", "the"), prepositions ("of", "on", "to", "in", "with"), and connectors ("and", "or", "but") add length without adding search value. Search engines weight these words as nearly zero anyway, so removing them is free. The "Drop stop words" toggle on this tool does this automatically — turn it on and watch the length crash.

That said, do not strip a stop word that changes meaning. the-great-gatsby is the title of the book; great-gatsby is something else. Use judgment.

Match how people actually search

Slugs are SEO real estate. Pick keywords that match the user query, not the marketing line. If your post is titled "We Reimagined the Way You Manage Tasks," nobody types that into Google — the matching slug is task-management-app or simple-task-manager, not we-reimagined-task-management.

Run the slug through your own search engine. Does it answer "what someone would type to find this page"? If not, rewrite.

Accents and Unicode

Every slug should be ASCII. URLs technically support Unicode through percent-encoding, but naïve becomes na%C3%AFve when shared, which looks ugly in tweets and breaks line wrapping in chat clients. Transliterate to plain ASCII at slug-generation time and skip the problem entirely.

Common transliterations: é → e, ö → o, ñ → n, ü → u, ç → c. The "Transliterate accents" toggle on this tool runs Unicode normalization (NFD) and strips combining marks — the standard, well-tested algorithm.

Never change a published slug

Once a slug is live, every link to it is now a live address. Change the slug and every link 404s. If you absolutely must change it (you typo'd, you legally have to, the old one is cursed), set up a 301 redirect from the old slug to the new one before pushing the change. Search engines transfer the ranking history through 301s; bare changes lose it.

The simplest rule: spend two extra minutes picking the right slug at publish time, and you will never need to change it.