Slugify Text
Turn any title or phrase into a clean, URL-safe slug as you type.
About the Slugify Text
The Slugify Text tool turns any title, headline, or phrase into a clean, URL-safe slug — the short, readable string that lives at the end of a web address, like my-first-post. It lowercases your text, trims stray whitespace, swaps spaces and underscores for a single separator, strips accents and diacritics down to their plain letters, removes anything that isn't a letter, number, or separator, and finally collapses repeated separators and trims them from the ends. The result is a tidy slug you can drop straight into a URL, filename, anchor link, or database key. Everything happens live in your browser as you type, so there is no upload, no sign-up, and no waiting.
Slugs matter because URLs should be predictable and human-readable. A page at /blog/how-to-bake-bread is easier to read, share, and remember than one at /blog/post?id=8821, and search engines treat a descriptive slug as a small but real ranking and click-through signal. Doing this by hand is tedious and error-prone: it's easy to leave in a stray capital, an apostrophe, an "é", or a double space that breaks a link or looks messy. This tool applies the same rules every time so your slugs stay consistent across an entire site.
How to use
- Type or paste your title or phrase into the input box. The slug below updates on every keystroke.
- Pick a separator. Choose a hyphen ( - ), which is the web standard for URLs, or an underscore ( _ ) if your system or filenames prefer it.
- Toggle lowercase. It's on by default, since most URLs are conventionally lowercase; turn it off if you need to preserve the original letter case.
- Read the slug in the monospaced readout. It shows exactly the string that will be produced.
- Copy or clear. Use "Copy slug" to put the result on your clipboard, or "Clear" to empty the box and start again.
A few details about how the slug is built:
- Accents are stripped by normalizing the text and removing combining marks, so "Café Déjà" becomes
cafe-dejarather than dropping the letters entirely. - Spaces and underscores are treated as word boundaries and replaced with your chosen separator, so "hello world" and "hello_world" both produce the same result.
- Unsupported characters — punctuation, symbols, emoji — are removed rather than transliterated, keeping the slug strictly to letters, numbers, and the separator.
- Repeated separators collapse to one, and any at the very start or end are trimmed, so " Hello -- World! " yields a clean
hello-world.
Frequently asked questions
What exactly is a URL slug?
A slug is the human-readable part of a URL that identifies a specific page, usually derived from its title — for example, the getting-started-guide in example.com/docs/getting-started-guide. Good slugs are short, lowercase, and use hyphens between words so both people and search engines can read them at a glance.
Does my text get uploaded or saved anywhere?
No. The entire conversion runs locally in JavaScript on your device. Nothing you type is sent to a server, stored, or logged. Close the tab and the text is gone.
Should I use hyphens or underscores?
For public web URLs, hyphens are the standard and are recommended by most search engines, which treat a hyphen as a word separator. Underscores are common in filenames, code identifiers, and some content systems. This tool supports both so you can match whatever your platform expects.
How are accented and non-English characters handled?
Accented Latin letters are normalized to their base form, so "à", "ñ", and "ü" become a, n, and u. Characters from scripts that have no Latin equivalent — such as Chinese, Arabic, or emoji — are removed, since they can't be safely represented in a plain ASCII slug. If a title is entirely non-Latin, you may want to supply an English version to slugify instead.
Why did some characters disappear from my slug?
The tool keeps only letters (a–z), digits (0–9), and your chosen separator. Everything else — apostrophes, quotation marks, ampersands, slashes, emoji, and other symbols — is stripped so the slug stays valid in a URL. That's why "Rock & Roll!" becomes rock-roll.
Can I keep uppercase letters in the slug?
Yes. Turn off the "Lowercase" toggle and the original letter case is preserved. This is useful for case-sensitive systems or when a slug needs to match an existing capitalized identifier, though lowercase remains the safest default for web URLs.