What Is Text Case?
Text case describes the capitalisation pattern applied to letters in a piece of text. In English and most Latin-script languages, letters can be uppercase (capitals) or lowercase, and different conventions apply in different contexts. Writing uses sentence case and title case. Programming uses camelCase, snake_case, and kebab-case. Design and marketing use ALL CAPS for emphasis and Title Case for headings.
The concept of uppercase and lowercase originates from physical printing. In a typesetter's type case, capital letters were stored in the upper section (upper case) and small letters in the lower section (lower case). These terms entered everyday language and remain the standard names for capital and small letters today.
Text case conversion is a routine task for developers, writers, marketers, and content managers. Renaming variables between programming languages often requires converting snake_case to camelCase. Importing data often requires normalising inconsistent capitalisation. Formatting blog post titles requires applying title case rules. Online case converters handle all these transformations instantly.
How Text Case Works
Basic case conversions — all uppercase, all lowercase — are straightforward: change every letter to its capital or small form. Sentence case capitalises the first letter of each sentence and lowercases the rest. Title Case capitalises the first letter of each major word (typically excluding short prepositions and articles like "of", "the", "and"). Different style guides (APA, Chicago, AP) have slightly different title case rules.
Programming case conventions: camelCase capitalises each word except the first (firstName, getUserById). PascalCase capitalises every word including the first (FirstName, GetUserById). snake_case uses underscores as word separators in lowercase (first_name, get_user_by_id). kebab-case uses hyphens (first-name, get-user-by-id). SCREAMING_SNAKE_CASE is snake_case in all caps, used for constants.
Examples of Text Case
- hello world → HELLO WORLD (uppercase)
- HELLO WORLD → hello world (lowercase)
- hello world → Hello World (title case)
- HELLO WORLD → Hello world (sentence case)
- hello world → helloWorld (camelCase)
- hello world → hello_world (snake_case)
- hello world → hello-world (kebab-case)
Where Is Text Case Used?
- Variable renaming: converting database column names (user_first_name) to JavaScript variables (userFirstName) or vice versa
- Content formatting: applying title case to blog post headings, product names, and article titles consistently
- Data cleaning: normalising imported data where capitalisation is inconsistent across rows
- URL slug generation: converting "My Blog Post Title" to "my-blog-post-title" (kebab-case)
- Writing editing: converting accidentally ALL-CAPS text back to sentence case, or fixing mixed-case headings