Skip to content

camelCase Converter

Convert any text, snake_case, or kebab-case to camelCase. Free online camelCase converter for JavaScript, Java, and TypeScript identifiers.

A camelCase converter joins words together with no separators, lowercasing the first word and capitalising the first letter of every word after it, like userFirstName. It is the standard variable naming convention in JavaScript, Java, and TypeScript.

Examples

InputOutput
user first nameuserFirstName
HTTP_RESPONSE_CODEhttpResponseCode
get-user-by-idgetUserById

When to use the camelcase converter

camelCase is the default identifier style for variables, function names, and object properties in a large share of the ecosystem:

  • JavaScript and TypeScript. Variables and functions, per the Airbnb and Google style guides. Class names use PascalCase instead.
  • Java. Methods and fields; classes are PascalCase and constants are SCREAMING_SNAKE_CASE.
  • JSON APIs. Common in JavaScript-facing APIs, though snake_case dominates in Python, Ruby, and Rails backends.

This converter normalises whatever you paste. It splits on spaces, hyphens, underscores, and existing case boundaries, so HTTP_RESPONSE_CODE, http-response-code, and HTTP Response Code all converge on httpResponseCode.

A note on acronyms: style guides disagree on whether to write parseHTTPResponse or parseHttpResponse. Google's JavaScript guide prefers the second — treat acronyms as ordinary words — which is what this converter produces.

Frequently asked questions

What is the difference between camelCase and PascalCase?

camelCase lowercases the first word (userName); PascalCase capitalises it (UserName). By convention camelCase names variables and functions, while PascalCase names classes and types.

Can it convert snake_case or kebab-case to camelCase?

Yes. The converter splits on underscores, hyphens, spaces, and existing capital letters, so any of those formats convert correctly in one step.

How are acronyms handled?

Acronyms are treated as ordinary words, so HTTP_RESPONSE becomes httpResponse rather than hTTPResponse. This matches the Google JavaScript style guide.