Elofyn Tools · /tools/slug

Slug generator

URL-safe slugs from any text. Unicode-aware transliteration, live preview, copy to clipboard — entirely in your browser.

What is this? →

Your input never leaves your browser.

Mode
Separator
Max length
chars (1–200)
Slug output
Slug appears here.
length: 0 chars

When to use it

A slug is the URL-safe segment of a path — mary-had-a-little-lamb instead of Mary%20had%20a%20little%20lamb%21. RFC 3986 reserves a small alphabet (letters, digits, hyphen, dot, underscore, tilde) for unreserved use; anything outside it must be percent-encoded, which is ugly, hostile to copy-paste, and breaks on a depressing variety of CMS, analytics, and email-link rewriters.

This tool converts arbitrary text into that safe alphabet, instantly, in your browser. It uses @sindresorhus/slugify, which performs Unicode-aware transliteration: Café résumé becomes cafe-resume, Москва becomes moskva, 東京タワー becomes dong-jing-tawa. Camel-case identifiers are split (getUserById get-user-by-id), repeated separators are collapsed, and the result is lower-cased and trimmed by default.

Typical reaches: drafting a blog post URL, cleaning a dump of titles before they hit a router, renaming files for S3 keys, or minting a stable identifier for a CMS record. Nothing leaves your browser. For why slugs exist and why transliteration is the hard part, see the full explainer.

Read the full explainer →