LocalFirstTools.com — data tools that never leave your device
No upload — everything runs on your device

Convert text to kebab-case

kebab-case lowercases words and joins them with hyphens: “Getting Started Guide” becomes getting-started-guide, and camelCase input like pageHeaderTitle becomes page-header-title. Type below and read the kebab-case row — it updates live.

kebab-case's home turf is the one place the other conventions cannot go: URLs, where search engines treat the hyphen as a word separator but the underscore as a word joiner — ten-tips indexes as two words, ten_tips as one token. The cost is symmetrical with snake_case: on our corpus's 244 unique keys, kebab-case averages 7.5 characters against camelCase's 7.2, one hyphen per word boundary.

camelCase
gettingStartedGuide
PascalCase
GettingStartedGuide
snake_case
getting_started_guide
kebab-case
getting-started-guide
CONSTANT_CASE
GETTING_STARTED_GUIDE

When it goes wrong

kebab-case cannot be a variable name in most languages — the hyphen parses as subtraction (page-header is page minus header) — so if code is the destination, you wanted the camelCase or snake_case row. If the output feeds a URL and contains characters beyond words (accents, symbols, “&”), this converter is the wrong size: the Slug Generator additionally strips diacritics and maps symbols to words.

When to use this

kebab-case is the convention for URLs, web file names, CSS classes and custom HTML attributes — case-insensitive contexts where underscores are awkward.

This page is a focused view of theCase Converter, which has the full set of options.

Frequently asked questions

Why kebab-case for URLs instead of underscores?

Search engines treat hyphens as word separators but tend to treat underscores as joiners, so ten-tips reads as two words while ten_tips reads as one. Hyphens are also visible inside underlined links.

Can kebab-case be used for variable names?

Not in most languages — the hyphen parses as subtraction. It lives in URLs, file names, CSS and HTML, while code uses camelCase or snake_case.