How to convert text to PascalCase
- Paste your words or names into Input, one per line.
- Each line becomes one PascalCase name with a capital at the start of every word.
- Copy the result or download it.
Where PascalCase is used
PascalCase is the standard for class names in Java, C#, Python, TypeScript and many other languages. In C# it is also used for methods and properties. React requires component names to start with a capital, so components such as UserProfileCard are written in PascalCase, and TypeScript types and interfaces usually follow the same style.
When you turn a database table, a file name or a plain description into a class name, this converter saves retyping each word. It also works the other way round from camelCase: httpClient becomes HttpClient. For variable names, use the camelCase converter.
Splitting the words
Words are split at spaces, underscores, hyphens, punctuation and at every point where a lowercase letter meets a capital. Numbers stay attached to the word before them, so html5 parser becomes Html5Parser. A name can’t start with a digit in most languages, so if a line starts with a number, put a word in front of it before you use the result.