Text Case Converter
Switch text between the naming conventions developers actually use, without destroying the word boundaries already in your input.
| Result | Start typing and every convention updates live. |
The hard part is not casing — it is finding the words
Any tool can uppercase a string. The reason most case converters produce garbage is that they
split on spaces and underscores only, so parseHTTPResponse becomes
parse_h_t_t_p_response. Getting this right means detecting boundaries that are
not written down:
- Explicit separators — spaces, underscores, hyphens, dots, slashes.
- Camel humps — a lowercase letter followed by an uppercase one, as in
userId. - Acronym boundaries —
HTTPResponsesplits intoHTTPandResponse, because a run of capitals followed by a capital plus lowercase marks the end of the acronym.
This tool applies all three rules before re-casing, so round-tripping between conventions does not progressively destroy your identifiers.
Worked example
| Input | camelCase | snake_case | kebab-case |
|---|---|---|---|
user_id | userId | user_id | user-id |
parseHTTPResponse | parseHttpResponse | parse_http_response | parse-http-response |
User ID | userId | user_id | user-id |
XMLHttpRequest | xmlHttpRequest | xml_http_request | xml-http-request |
2 fast 2 furious | fastFurious | fast_furious | fast-furious |
Note the last row: leading digits are dropped, because an identifier cannot start with a digit in most languages. Numbers in the middle of a word are preserved.
Which convention, where
| Language | Variables / functions | Types / classes | Constants |
|---|---|---|---|
| JavaScript, Java, TypeScript, C# | camelCase | PascalCase | CONSTANT_CASE |
| Python, Ruby | snake_case | PascalCase | CONSTANT_CASE |
| Go, Rust | camelCase / snake_case | PascalCase | CONSTANT_CASE |
| CSS, HTML, URLs, file names | kebab-case — lowercase and hyphenated, because host names and many file systems are case-insensitive | ||
| SQL | snake_case | Unquoted identifiers fold to upper case in most engines, so consistency matters more than the choice | |
URL slugs are not just case conversion. Lowercasing and hyphenating is only the first step. A slug also needs Unicode transliteration, diacritic stripping and removal of characters that are unsafe in a path. Converting case alone will leave you with broken links for any non-ASCII title.
Frequently asked questions
Why did my acronym get split into separate letters?
The input did not mark the boundary. parseHTTPResponse is handled correctly, but PARSEHTTPRESPONSE has no humps or separators to work from and is read as one word.
Can I convert a whole source file?
Yes, paste as much text as you like. Be aware that casing is applied to everything, including string literals and comments, so review the result before committing it.
What is the difference between Title Case and Sentence case?
Title Case capitalises every word. Sentence case capitalises only the first word of each sentence, which is what most prose and UI copy should use.
Does it handle non-Latin alphabets?
Casing follows Unicode rules where the browser supports them. Word splitting relies on Latin letters and digits, so scripts without spaces such as Chinese or Japanese are treated as a single word.
Privacy. Your text is processed in your browser and never uploaded, so it is safe to run over real identifiers, config keys and proprietary copy.