Skip to content
Deftkit

Text Case Converter — camelCase, snake_case, kebab-case

Convert text between camelCase, snake_case, kebab-case, PascalCase, UPPER, lower, Title Case, and more. Free, fast, runs entirely in your browser.

Type any text — the tool detects word boundaries (camelCase transitions, snake_case separators, spaces, digits) and converts to all common cases in real time.

camelCasehelloWorldThisIsATestStringVersion2Release
PascalCaseHelloWorldThisIsATestStringVersion2Release
snake_casehello_world_this_is_a_test_string_version_2_release
CONSTANT_CASEHELLO_WORLD_THIS_IS_A_TEST_STRING_VERSION_2_RELEASE
kebab-casehello-world-this-is-a-test-string-version-2-release
dot.casehello.world.this.is.a.test.string.version.2.release
path/casehello/world/this/is/a/test/string/version/2/release
Title CaseHello World This Is A Test String Version 2 Release
Sentence caseHello world this is a test string version 2 release
UPPER CASEHELLO WORLD — THIS IS A TEST_STRING, VERSION2RELEASE
lower casehello world — this is a test_string, version2release

Why so many cases?

Different languages and communities settled on different word-joining conventions for identifiers, and now we all live with the result. JavaScript prefers camelCase for variables. Python prefers snake_case. Ruby too. CSS uses kebab-case. Constants are usually SCREAMING_SNAKE. File paths use slashes. Titles use Title Case. DNS labels use lowercase with hyphens. When you're moving text between contexts — renaming a prop that comes from a JSON API, or generating a URL slug from a blog post title, or turning a database column name into a human-readable label — you need a fast way to switch between them.

This tool detects word boundaries in whatever text you paste, then renders it in all the common cases simultaneously. Type once, copy the one you need.

Every case at a glance

Input: "Hello World Foo"

camelCase        helloWorldFoo
PascalCase       HelloWorldFoo
snake_case       hello_world_foo
CONSTANT_CASE    HELLO_WORLD_FOO
kebab-case       hello-world-foo
dot.case         hello.world.foo
path/case        hello/world/foo
Title Case       Hello World Foo
Sentence case    Hello world foo
UPPER CASE       HELLO WORLD FOO
lower case       hello world foo

How word boundaries are detected

The tool tokenizes your input by combining several heuristics, which matters because you can paste any existing style and still get correct conversions:

  • Separators: spaces, hyphens, underscores, slashes, dots, and any other non-alphanumeric character split the input into chunks
  • Lowercase → uppercase transitions inside a chunk become split points: camelCase splits into camel + Case
  • Uppercase run followed by uppercase+lowercase splits the run: XMLHttpRequest splits into XML + Http + Request
  • Letter → digit transitions: version2 splits into version + 2
  • Digit → letter transitions: 2Release splits into 2 + Release

Combined, this means you can paste a messy mix of styles (HTTPServer_versionUS2_release — final) and get a sensible tokenization that converts cleanly to any target case.

When to use each case

  • camelCase — JavaScript variables and function names, Java methods, JSON keys by convention
  • PascalCase (also called UpperCamelCase) — class names in most languages, React component names, TypeScript types and interfaces
  • snake_case — Python variables and functions, Ruby, Rust (for local variables), most SQL conventions
  • CONSTANT_CASE (SCREAMING_SNAKE) — environment variables, C/C++ macros, named constants in many languages
  • kebab-case — CSS class and property names, HTML attribute names, URL slugs, Linux command-line flags, DNS labels
  • dot.case — namespaced config keys (database.host), object-dot paths, file extension chains
  • path/case — URL paths, filesystem paths, hierarchical keys
  • Title Case— headings, book titles, proper formatting for UI labels. This tool capitalizes every word; for strict AP-style title case (which leaves articles and short prepositions lowercase) you'll need a dedicated tool
  • Sentence case — prose sentences, the first word capitalized and the rest lowercase
  • UPPER CASE / lower case — basic text transforms, no tokenization needed. These two operate on the raw input without splitting, so they preserve spaces and punctuation

Edge cases the tokenizer handles correctly

Input                      Tokens
───────────────────────    ────────────────────────
helloWorld                 hello, World
HelloWorld                 Hello, World
hello_world                hello, world
hello-world                hello, world
HTTP_SERVER                HTTP, SERVER
XMLHttpRequest             XML, Http, Request
version2                   version, 2
v2Release                  v, 2, Release
iOS 17 Release             iOS, 17, Release
user.address.city          user, address, city
path/to/file               path, to, file
— messy!! spacing —        messy, spacing

Privacy

All conversion happens in your browser. The text you type never leaves your device. There is no upload, no log, no analytics on the content itself.

Frequently asked questions

Does Title Case know which words not to capitalize?

No — this tool capitalizes every token, which is the style most codebases and UI labels use. If you need proper editorial title case (which leaves articles like a, the, of, andlowercase except at the start), you'll need a tool that implements a specific style guide like AP, Chicago, or MLA. Those are language-dependent and not in scope here.

Why does "HTTPServer" tokenize as HTTP + Server and not HTTPS + erver?

The regex detects the transition from an uppercase run to an uppercase letter followed by a lowercase letter. Inside HTTPServer, the split point is between P and S because S is followed by a lowercase e. The algorithm correctly identifies HTTP as the acronym and Server as the following word. This handles most acronym-plus-word patterns (XMLParser, URLShortener, IOError) correctly.

What about Unicode? Does it handle non-Latin scripts?

The tokenizer uses the regex class [^a-zA-Z0-9] for separator detection, which means non-Latin letters (CJK, Cyrillic, Arabic, etc.) are treated as separators and will split the input aggressively. For ASCII text it works perfectly; for mixed-script input the results may surprise you. This is a known limitation — proper Unicode-aware tokenization is on the roadmap.

Can I convert to random or mocking case (sPoNgEbOb)?

Not in this version. Alternating case is a separate novelty category; this tool focuses on the cases developers and writers actually use in code and content. If there's demand, it could be added as an eleventh output.

Is my data sent anywhere?

No — the tool runs entirely in your browser. Text conversion is a handful of regex and string operations, no network required.