Skip to content

Convert text to kebab-case

Convert sentences or camelCase to kebab-case, the ideal format for URL slugs, file names and CSS class names.

Processed on your device. Nothing is sent to any server.

Detects separators and case changes, then joins the lowercase words with hyphens, ready to use in a URL.

Use cases

  • Generating a URL slug from a title.
  • Naming CSS classes.
  • Converting file names to a consistent format.

How it works

  1. 1

    Paste your text

    Type a sentence or camelCase on the left.

  2. 2

    Copy the result

    The kebab-case text appears automatically on the right.

Technical details

  • Examples: "My First Article" → my-first-article; "backgroundColor" → background-color; "user_name" → user-name.
  • Accented letters are kept. For a URL slug with no special characters, remove them first: "café" → "cafe".
  • Consecutive capitals are treated as one word: "XMLHttpRequest" splits into "xmlhttp" and "request".

Frequently asked questions

Does it strip special characters?

It turns spaces, underscores and case changes into hyphens; characters that aren't letters, digits or those separators are kept as-is.

← Text