Case Converter

Convert identifiers between camelCase, PascalCase, snake_case, kebab-case and CONSTANT_CASE. Your data never leaves your browser.

100% client-side

Input

Type or paste one identifier per line

Results

camelCase

          
PascalCase

          
snake_case

          
kebab-case

          
CONSTANT_CASE

          

What is a naming case?

A "case" is a convention for writing multi-word names — variables, functions, files — as a single unbroken identifier, since most programming languages don't allow spaces inside a name. Different languages and style guides expect different conventions: JavaScript typically uses camelCase, Python uses snake_case, classes often use PascalCase, and URLs/CSS use kebab-case. This tool takes any identifier and converts it into all of them at once, so you don't have to retype it by hand for each context.

How to use Case Converter

  1. Type or paste one identifier per line into the Input panel (or click Example).
  2. The Results panel updates instantly, showing the same identifier(s) in camelCase, PascalCase, snake_case, kebab-case and CONSTANT_CASE.
  3. Click Copy next to any format to copy just that version.

How case conversion works

Every conversion happens in two steps: first the identifier is split into a list of words, then that same list is rejoined using each target convention's own rules. Splitting correctly means handling three kinds of boundaries — a lowercase letter followed by an uppercase letter, an uppercase acronym run followed by a title-case word, and a letter next to a digit — while treating _, - and spaces as plain delimiters:

// Split
"myURLValue" → ["my", "URL", "Value"]

// Rejoin
camelCase       → myUrlValue
PascalCase      → MyUrlValue
snake_case      → my_url_value
kebab-case      → my-url-value
CONSTANT_CASE   → MY_URL_VALUE

A standalone acronym like URL or ID stays as one word instead of being split into individual letters — the rule only splits an uppercase run right before the last letter when that letter starts a new lowercase word, e.g. UserID → User + ID, not five single letters.

Frequently asked questions

Is it safe to paste real variable or class names here?

Yes. Everything runs locally in your browser with plain JavaScript; nothing you type or paste is ever sent to a server.

How does it handle acronyms like URL or ID?

It treats a run of uppercase letters as one word unless it's followed by a lowercase letter, so "getUserID" splits into "get", "User", "ID" instead of shattering "ID" into two separate letters.

What happens to a leading underscore, like _private?

A single leading or trailing underscore or dash is preserved as a convention marker instead of being dropped — "_private" becomes "_Private" in PascalCase and "_PRIVATE" in CONSTANT_CASE.

Can I convert more than one identifier at a time?

Yes. Paste one identifier per line and every line is converted into all five formats at once, in matching order — an empty line is skipped instead of producing a blank row.