Text to Slug Converter

Generate URL slugs


          

What Is This Tool?

The Text to Slug Converter turns any title, heading, or phrase into a clean, URL-friendly slug. It lowercases the text, strips accents from letters, and replaces spaces and punctuation with your chosen separator, producing a slug suitable for blog post URLs, file names, or IDs.

How to Use

1

Type or paste your text into the input box.

2

Choose a separator (hyphen or underscore) and lowercase option.

3

The slug updates live, or click Generate Slug.

4

Copy the generated slug.

Features

  • Live slug generation as you type
  • Choice of hyphen or underscore separator
  • Strips accents from letters (e.g. é → e)
  • Optional lowercase conversion
  • 100% client-side — nothing leaves your browser

Examples

Input: Hello World! Café à la Mode

Output: hello-world-cafe-a-la-mode

Common Use Cases

  • Generating a URL slug for a blog post or article title
  • Creating clean file names from document titles
  • Building consistent IDs or anchor tags from headings
  • Preparing category or tag names for use in a URL path

Frequently Asked Questions

What is a slug?

A slug is a URL-friendly version of a string, usually lowercase, with spaces and special characters replaced by hyphens or underscores, commonly used in blog post URLs like /blog/my-post-title.

How are accented characters handled?

Accented letters are normalized to their base form using Unicode NFD normalization, so "café" becomes "cafe" and "à" becomes "a" before the slug is built.

What happens to punctuation and symbols?

Any run of one or more characters that aren't letters or numbers is replaced with a single separator, and separators are trimmed from the start and end of the result.

Can I use an underscore instead of a hyphen?

Yes, select the underscore option and the slug will use underscores as the separator instead of hyphens.

Is my text sent anywhere?

No. The slug is generated entirely in your browser using JavaScript. Nothing is uploaded or stored.