Skip to content
CaseConverterHQ

camelCase converter

Turn a phrase, a column name or an existing identifier into camelCase. Paste a whole column of names and each line is converted on its own.

Change the case

Programmer cases

Lines and spacing

Paste some text and choose a conversion.

Words
0
Characters
0
No spaces
0
Sentences
0
Paragraphs
0
Lines
0
Read time
0 sec

Nothing you paste leaves your browser — every conversion runs on this page. Check this before you rely on it. This text converter is provided free and without warranty, and its results are not professional advice.

camelCase and PascalCase are the same rule, offset by one

Both join words with no separator and capitalise each word. The only difference is the first word: camelCase leaves it lowercase (userFirstName), PascalCase raises it (UserFirstName). PascalCase is also called upper camel case, which is where most of the confusion comes from.

The split is by language convention, not by taste. JavaScript, Java, Kotlin, Swift and PHP use camelCase for variables and methods and PascalCase for classes and types. C# uses PascalCase for public members and camelCase for parameters and locals. Go uses the initial capital as an access modifier — an exported identifier must start with a capital, so the case is not a style question there at all.

What happens to acronyms

Words are found by splitting on spaces, underscores, hyphens and case boundaries, with acronyms kept whole: XMLHttpRequest splits to XML, Http, Request rather than to eleven fragments. Converted to camelCase that gives xmlHttpRequest.

Whether an acronym should stay shouted inside an identifier is a live argument. Microsoft's .NET guidelines say to treat acronyms longer than two letters as words — XmlHttpRequest, parseUrl — because parseURLFromHTTPResponse is genuinely hard to read. Java's standard library does both, sometimes in the same class. This converter normalises to the readable form; if your codebase shouts its acronyms, that is a manual fix rather than a rule anyone can automate.

Punctuation and numbers

Anything that is not a letter or a digit is treated as a word separator and dropped, so Order Total (USD) becomes orderTotalUsd. Digits stay attached to the word they were part of — version 2 beta becomes version2Beta — because splitting on digits produces identifiers nobody would have written by hand.

One thing the converter deliberately does not do is validate the result against any language. An identifier starting with a digit, or one that collides with a reserved word like class or new, comes back exactly as the input implies. Checking that belongs to your compiler, which will do it better.

Worked examples

Run through the same code the button runs, so the examples cannot drift from the tool.

InputcamelCase
user first nameuserFirstName
user_first_nameuserFirstName
XMLHttpRequestxmlHttpRequest
Order Total (USD)orderTotalUsd

Common questions

What is the difference between camelCase and PascalCase?

Only the first letter. camelCase starts lowercase (userFirstName), PascalCase starts uppercase (UserFirstName). PascalCase is sometimes called upper camel case.

How does the converter handle acronyms like XML or URL?

Acronyms are detected as whole words, so XMLHttpRequest becomes xmlHttpRequest rather than being split letter by letter. The acronym is normalised to ordinary word capitalisation, which is what most modern style guides recommend.

Can I convert a whole list of names at once?

Yes. Each line is converted independently, so you can paste a column of column names or CSV headers and get one identifier per line back.

Other text tools