TextToolboxTextToolbox
Glossary

Text Case

Text case refers to the capitalisation pattern of letters in text — uppercase, lowercase, title case, sentence case, camelCase, snake_case, and other conventions used in writing and programming.

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

Try These Free Tools

See Text Case in action — free, no sign-up required.

Related Terms

Frequently Asked Questions

What are the most common text case types?+

The most common types are: uppercase (ALL CAPS), lowercase (all small letters), Sentence case (first letter of sentence capitalised), Title Case (first letter of each major word capitalised), camelCase (JavaScript variables), PascalCase (class names), snake_case (Python and database columns), and kebab-case (URL slugs and CSS classes). Programming also uses SCREAMING_SNAKE_CASE for constants.

What is the difference between camelCase and PascalCase?+

Both join multiple words without spaces and capitalise the start of each word, but camelCase keeps the very first letter lowercase (firstName, getUserById) while PascalCase capitalises the first letter of every word including the first (FirstName, GetUserById). PascalCase is also called UpperCamelCase or StudlyCase. In programming, camelCase is common for variables and functions; PascalCase is common for class names.

What is title case and when should I use it?+

Title case capitalises the first letter of every significant word in a heading or title. Short words like "a", "an", "the", "in", "of", and "and" are typically not capitalised unless they are the first word. Use title case for blog post titles, book chapter headings, product names, and UI labels. Different style guides (AP, Chicago, APA) have slightly different rules about which words to capitalise.

How do I convert between snake_case and camelCase?+

To convert snake_case to camelCase: split the string at each underscore, capitalise the first letter of each segment except the first, then join them without separators. To go the other way: insert an underscore before each uppercase letter, then convert everything to lowercase. An online case converter handles this automatically — paste your text, choose the target case, and copy the result.

Does case matter in URLs?+

On most web servers (Linux-based), URLs are case-sensitive — /My-Page and /my-page are different URLs. On Windows servers, they are case-insensitive. For SEO and consistency, best practice is to use lowercase kebab-case URLs (/my-page-title) and set up redirects if old URLs used different capitalisation. Google treats URLs as case-sensitive by default.