Case Converter

Type once, get 14 conventions. camelCase, snake_case, kebab-case, and eleven more.

Splits on spaces, hyphens, underscores, dots, slashes, and camelCase boundaries.

Type text above to see all 14 case conversions

How the Case Converter Works

Type or paste any text — the tool first splits it into 'words' by detecting boundaries: spaces, underscores, hyphens, dots, slashes, and camelCase transitions (e.g. 'helloWorld' → ['hello', 'World']). Then each of the 14 case formats applies its own join rule to that word list.

The split is intentionally aggressive: it handles mixed inputs like 'some-slug_to convert.to/any_case' seamlessly. Each conversion card shows the result, the framework or context where that casing is standard, and a copy button.

References & Conventions

There is no single RFC governing naming conventions — they vary by language and ecosystem. The general topic is documented in the Wikipedia: Naming convention (programming) article.

Ecosystem standards: camelCase — JavaScript, Java, TypeScript variables and methods. PascalCase — classes and components in most OOP languages. snake_case — Python (PEP 8), Ruby, SQL column names, file names. kebab-case — CSS class names, HTML attributes, URL slugs, CLI flags. SCREAMING_SNAKE_CASE — environment variables, constants in Python/C/Go. Train-Case — HTTP headers (Content-Type, X-Api-Key).

What's here — and what's not

14 case formats: UPPERCASE, lowercase, Title Case, Sentence case, camelCase, PascalCase, snake_case, kebab-case, SCREAMING_SNAKE_CASE, Train-Case, dot.case, path/case, aLtErNaTiNg CaSe, and iNVERSE cASE. Splits on spaces, hyphens, underscores, dots, slashes, and camelCase boundaries. Each card shows the ecosystem where the format is standard.

What isn't here: locale-aware title casing (The Chicago Manual of Style rules for articles and prepositions), unicode-specific casing for non-Latin scripts, smart capitalization that skips words like 'and'/'of' in titles, or bulk file renaming. This tool is a plain text converter — for code-aware renaming, use your IDE's rename refactoring.

Frequently Asked Questions

Which case should I use in JavaScript?
In JavaScript and TypeScript: camelCase for variables, parameters, and function names (e.g. getUserName); PascalCase for classes, React components, and TypeScript types/interfaces (e.g. UserProfile); SCREAMING_SNAKE_CASE for module-level constants (e.g. MAX_RETRY_COUNT); kebab-case for CSS classes and HTML attributes.
Which case does Python use?
Python follows PEP 8: snake_case for variables, functions, and module names; PascalCase (CapWords) for class names; SCREAMING_SNAKE_CASE for constants. Package names use all-lowercase (no underscores preferred). These conventions are enforced by linters like flake8, pylint, and ruff.
How does the word split work for camelCase input?
The splitter uses two regex rules to find camelCase boundaries: (1) a lowercase letter followed by an uppercase letter — e.g. 'helloWorld' splits into ['hello', 'World']; (2) a sequence of uppercase letters followed by an uppercase+lowercase — e.g. 'HTMLParser' splits into ['HTML', 'Parser']. Then it also splits on spaces, underscores, hyphens, dots, and slashes.
What is Train-Case used for?
Train-Case (also called HTTP-Header-Case) capitalizes the first letter of each word and separates with hyphens: Content-Type, X-Api-Key, Authorization. HTTP/1.1 headers are conventionally written in Train-Case, though HTTP/2 lowercases all headers internally. It is also occasionally used in some configuration file formats.