Skip to content

PascalCase Converter

Convert text, snake_case, or kebab-case to PascalCase. Free online PascalCase converter for class names and type names.

A PascalCase converter joins words with no separators and capitalises the first letter of every word, including the first, like UserFirstName. It is the conventional naming style for classes, types, and components.

Examples

InputOutput
user first nameUserFirstName
shopping_cart_itemShoppingCartItem
nav-barNavBar

When to use the pascalcase converter

PascalCase — also called upper camel case — signals "this is a type, not a value" across most of the industry:

  • Classes and interfaces in Java, C#, TypeScript, Swift, and Kotlin.
  • React and Vue components. React specifically requires it: a lowercase JSX tag is treated as an HTML element, so <navBar /> silently renders nothing while <NavBar /> renders your component.
  • C# methods and properties, which unusually use PascalCase where Java would use camelCase.
  • Enum members and type aliases in most statically typed languages.

The convention is load-bearing rather than cosmetic. Linters such as ESLint's react/jsx-pascal-case rule will fail a build over it, and in React the difference between PascalCase and camelCase changes what the code actually does.

Frequently asked questions

Is PascalCase the same as camelCase?

No. Both remove separators and capitalise interior words, but PascalCase also capitalises the first letter. UserName is PascalCase; userName is camelCase.

Why must React components use PascalCase?

JSX treats lowercase tags as built-in HTML elements and capitalised tags as components. A component named navBar will not render — React looks for an HTML element called navbar instead.

Is PascalCase also called upper camel case?

Yes, the two terms are interchangeable. "Upper camel case" is more descriptive; "PascalCase" comes from the Pascal language, which popularised the style.