PascalCase Converter
Convert any phrase into PascalCase — every word capitalised, no separators. Standard for class names, types, and React components.
user profile background color → UserProfileBackgroundColor
Convert any phrase into PascalCase — every word capitalised, no separators. Standard for class names, types, and React components.
user profile background color → UserProfileBackgroundColor
PascalCase (sometimes called UpperCamelCase or StudlyCaps) is a naming convention where every word starts with an uppercase letter and there are no separators between words. It's the standard for class names, type names, and constructor functions in nearly every modern language.
The convention is named after the Pascal programming language (1970s), which used it for type names. The closely-related camelCase differs only in the first letter — PascalCase capitalises the first word; camelCase lowercases it.
UserProfile, HttpClient, OrderRepository. Java, C#, TypeScript, Swift, Kotlin, and Python (PEP 8) all use PascalCase for class names regardless of what they use for variables.
React requires component names to be PascalCase — <UserCard /> not <userCard />. JSX uses the casing to decide whether a tag is a custom component (capitalised) or an HTML element (lowercase).
Interface names (UserSettings, ApiResponse) and type aliases are PascalCase. Some teams prefix interfaces with I (IUserSettings); the modern TypeScript convention is to skip the prefix.
Most languages use PascalCase for enum members: OrderStatus.Pending, HttpStatus.NotFound. (Some older C++ code uses CONSTANT_CASE for enums; modern usage favours PascalCase.)
If a file defines a class, the file name often matches the class name in PascalCase: UserProfile.tsx, OrderService.cs.
The PascalCase converter parses the input string into tokens by splitting on all non-alphanumeric characters (spaces, hyphens, underscores, dots, etc.). Each token is then capitalised: the first character is uppercased, and the remaining characters are lowercased. The tokens are concatenated without any separator. This process follows the standard CamelCase capitalisation rule, but crucially it does not preserve all-uppercase acronyms — HTTPRequest becomes Httprequest (or HttpRequest if the input has word breaks). The algorithm uses Unicode-aware case mapping via the ECMA-262 String.prototype.toUpperCase() and toLowerCase() methods, which handle accented and non-Latin characters correctly. Numbers are treated as part of a token (e.g., user2background becomes User2background), not split into separate words.
While you can achieve PascalCase with text-manipulation tools, this dedicated converter is faster and handles edge cases automatically.
| This tool | sed command | Excel PROPER() | |
|---|---|---|---|
| Handles hyphenated words | Splits on hyphens by default | Requires extra regex: sed 's/-/_/g' then separate script | Treats hyphen as non-word, but no direct PascalCase |
| Preserves acronyms (optional) | No – always lowercases rest | Can be scripted to detect all-caps, but complex | No – PROPER() lowercases everything after first letter |
| Batch processing | Single-input, web-based | Ideal for large files with pipes | Works on lists only with complex formulas |
PascalCase derives its name from the Pascal programming language, designed by Niklaus Wirth in the late 1960s and first published in 1970. Pascal used this naming convention for type identifiers and record field names, promoting readability at a time when many languages used all-uppercase or cryptic abbreviations. The convention later spread to other languages like C# and TypeScript, where it became the standard for class names, methods, and properties. Its alternative name, UpperCamelCase, contrasts with lowerCamelCase used for variables and functions.
Both are correct in different contexts. camelCase for variables, function names, and object properties. PascalCase for classes, types, and (in React) components. Most languages use both — they're complementary, not interchangeable.
The Pascal language (designed by Niklaus Wirth, 1970) used UpperCamelCase for type names — popularising the convention enough that it took the language's name. Pascal itself is no longer mainstream, but the naming convention outlived it.
Two schools of thought: full caps (HTTPClient, XMLParser) or treated-as-words (HttpClient, XmlParser). Microsoft and most modern style guides recommend the latter (treat acronyms ≥ 3 letters as words). It scans more uniformly inside long identifiers.
StudlyCaps is the same convention as PascalCase but the term is older (1980s) and slightly more informal. The two names refer to the identical pattern.