kebab-case Converter
Convert text or identifiers to kebab-case instantly.
This tool runs entirely in your browser. Your files are never uploaded to a server.
What this tool does
Splits text or identifiers into lowercase words and rejoins them with hyphens to produce kebab-case. It recognizes ordinary whitespace, common identifier separators, camelCase transitions, PascalCase boundaries, and acronym-to-word transitions.
How to use it
Paste a phrase or identifier and the kebab-case output appears immediately. Copy or reset the result as needed; the buttons above the editor also convert the same input to camel, Pascal, snake, dot, path, constant, or no case.
Worked example
Entering "HTTPServer_v2.0/TestValue" produces "http-server-v2-0-test-value". The acronym boundary, underscore, dot, slash, and lower-to-upper transitions all create word boundaries before joining.
Tokenization rules
The converter inserts boundaries between lowercase letters or digits and a following capital, and between an acronym and a capitalized word. Runs of underscores, hyphens, dots, slashes, or whitespace are treated as separators.
Output rules
Every detected word is lowercased and empty pieces are removed, then the remaining sequence is joined with one hyphen. Leading and trailing recognized separators therefore disappear, and repeated recognized separators collapse.
Limitations
Characters other than the recognized separators are not stripped: commas, quotes, symbols, and many punctuation marks can remain inside a token. The result is therefore not automatically a safe URL slug, CSS identifier, filename, or command-line option; validate it for that context.
Uses and privacy
kebab-case is common in CSS class names, configuration keys, command flags, and URL-like identifiers, but each platform can impose extra rules. Conversion runs locally in your browser and the entered text is not uploaded.
Frequently Asked Questions
- What is kebab-case used for?
- It's widely used for CSS class names, HTML attributes, command-line flags, and URL slugs, since hyphens are readable and URL-safe.
- Can I convert from snake_case or camelCase to kebab-case?
- Yes — the tool splits your input on underscores, dots, spaces, and existing camelCase/PascalCase boundaries before rejoining it with hyphens, so it works from any of those styles.
- Is kebab-case the same as a URL slug?
- They're effectively the same format — for turning full sentences or titles into clean URL slugs (with punctuation stripped), use the dedicated Text to Slug tool.