Skip to content
SmaftyTools

Text to Slug

Turn any title into a clean, SEO-friendly URL slug — lowercase, hyphenated and free of accents or special characters.

About Text to Slug

The Text to Slug tool converts titles and phrases into clean URL slugs: lowercase, hyphen-separated, with accented characters transliterated (é → e, ñ → n) and symbols removed. 'How to Make Great Coffee!' becomes 'how-to-make-great-coffee' — the process publishers commonly call slugifying a title.

It's used constantly by anyone publishing content or managing structured URLs: a blogger generating a URL slug from a post title, a store owner building consistent product-page slugs for an e-commerce catalog, a developer creating anchor IDs for a table of contents from section headings, and multilingual sites converting titles containing accents or unusual punctuation ('Café & Garçon', 'Wie geht's?') into ASCII-safe URLs that work in every browser and server without extra encoding.

Conversion handles more than a simple lowercase-and-hyphenate pass: accented and diacritic characters are transliterated to their closest plain-ASCII equivalent rather than stripped outright, ampersands convert to 'and' so the meaning of 'Rock & Roll' survives as 'rock-and-roll' instead of disappearing, and repeated whitespace or symbols collapse into a single separator rather than leaving double hyphens. A separator toggle switches between hyphens (the URL convention) and underscores (useful for code identifiers or filenames that shouldn't contain hyphens).

Clean slugs matter for both SEO and usability: they're readable directly in search results and browser address bars, safe in every server and CMS without percent-encoding, and stable enough that they rarely need to change. When choosing between hyphens and underscores for a URL, use hyphens — search engines treat hyphens as word boundaries but may read an underscore-joined phrase as a single unbroken term, which works against how the slug is meant to be found. Keep slugs under roughly 60 characters and focused on the page's main keywords, and once a slug is published, avoid changing it — doing so breaks existing links and loses any SEO value the URL had already accumulated.

How to Use the Text to Slug

  1. Type or paste your title or phrase.
  2. Pick a separator (hyphen for URLs, underscore for identifiers).
  3. Copy the generated slug.

Features

  • Accent and diacritic transliteration (café → cafe)
  • Removes symbols and collapses whitespace
  • Hyphen or underscore separators, optional lowercase
  • Works with any language's letters and numbers

Examples

Slugifying a blog title

Input

How to Make Great Coffee!

Output

how-to-make-great-coffee

Transliterating accents and ampersands

Input

Café & Garçon Menu

Output

cafe-and-garcon-menu

Using underscores for a code identifier

Input

User Profile Settings

Output

user_profile_settings

Frequently Asked Questions

Should I use hyphens or underscores in URLs?

Hyphens. Search engines treat hyphens as word separators but may read underscore-joined words as a single term. Use underscores only for code identifiers or filenames.

How long should a URL slug be?

Keep it under about 60 characters and focused on the main keywords. Drop filler words when they don't change the meaning.

What happens to numbers and existing hyphens in the title?

Numbers are kept as-is, and existing hyphens are preserved as separators rather than removed, so a title like 'Top 10 Best-Selling Books' becomes 'top-10-best-selling-books' with the meaning intact.

Is the slug generator free?

Yes, the slug generator is completely free with no usage limits. No signup, no account and no installation required.

Is my data safe?

Yes. All processing happens locally in your browser using JavaScript — nothing you type is uploaded or stored on our servers.