UPPERCASE, lowercase, Title Case: Case Conversion

Changing text case looks like the most trivial transformation in computing, and then Title Case asks which words stay small, sentence case wants to know where sentences start, and programmers turn out to have five competing cases of their own with religious followings. This guide covers the human cases, the code cases, and the two genuine traps, with our free case converter doing the conversions in your browser.

The human cases

  • UPPERCASE: headings, warnings, acronyms, and shouting. Harder to read in bulk because word shapes flatten, which is why long uppercase passages feel like work.
  • lowercase: the neutral state, and a deliberate style in branding and casual writing.
  • Sentence case: first letter of each sentence capitalized, the default of prose. Automation has to guess where sentences begin, and abbreviations (“e.g.”) are where it guesses wrong, so converted text deserves a skim.
  • Title Case: most words capitalized, the headline convention, with enough rules to earn its own section.

Title Case: the one with judgment in it

Title Case capitalizes principal words and leaves small words down, and the catch is that style guides disagree about which words are small: articles and short prepositions usually stay lowercase (“The Lord of the Rings”), but one tradition lowercases prepositions of any length while another capitalizes everything from four letters up. Three rules survive across all of them: the first and last word are always capitalized, both halves of a hyphenated compound usually are, and consistency within one document beats any particular rulebook. A converter applies one convention mechanically, which is exactly what you want for a list of fifty headings, with a human pass for the handful of judgment calls. For web headlines specifically, the quiet trend is sentence case anyway, one less rulebook to carry.

The programmer cases

Code needs multi-word names without spaces, and every solution became a convention with a name:

CaseExampleNative habitat
camelCaseuserFirstNameJavaScript, Java variables
PascalCaseUserFirstNameclass names, C#
snake_caseuser_first_namePython, SQL, config files
kebab-caseuser-first-nameURLs, CSS, filenames
SCREAMING_SNAKEUSER_FIRST_NAMEconstants

Conversions between them are mechanical, split on the word boundaries, rejoin in the new convention, and that mechanical job is what the camelCase to snake_case converter automates for whole files of identifiers. The one wrinkle is acronyms: is it parseHTML or parseHtml, HTTPServer or HttpServer? Both styles exist in the wild, conversion tools must pick one, and so should your codebase, once, in writing.

The two real traps

  • Case conversion destroys information. Lowercasing “US” gives “us”, uppercasing “it” gives “IT”, and no tool can restore what the original meant. Converting away from mixed case is one-way; keep the original when the text contains acronyms, names, or anything where capitalization was data, the same keep-the-master rule as every lossy transformation.
  • Case is language-dependent. The famous example is Turkish, where lowercase I is ı (dotless) and uppercase i is İ (dotted), so naive ASCII case rules corrupt Turkish text. German ß, Greek final sigma, and others have their own behaviors. For plain English the simple rules are exact; for international text, use Unicode-aware conversion, which is precisely the difference between the ASCII case converter and the Unicode-correct UTF-8 uppercase and lowercase tools, which handle accented and non-Latin scripts properly.

The toolbox

Frequently asked questions

Which case is best for file names?

kebab-case or snake_case, lowercase: they survive every filesystem, need no shift key, and avoid the case-sensitivity differences between operating systems, where Report.txt and report.txt may or may not be the same file.

Does case affect URLs and SEO?

Domains are case-insensitive; paths can be case-sensitive depending on the server, so /Page and /page may be different URLs. Lowercase paths, the universal convention, make the question disappear.

Why does my converted heading capitalize “And”?

The tool is applying a convention that capitalizes four-letter-plus words or simply every word. Pick the convention matching your style guide, or accept the tool’s and stay consistent; inconsistency is the only outright error.

Is there a case that avoids all ambiguity for data matching?

Lowercase plus Unicode normalization is the standard matching form: it folds the maximum number of equivalent variants together. That combination is exactly what dedupe tools apply when you enable their matching options.

ATV

Written by Nick (ATV Team)

We build and maintain the 600+ free, client-side tools on this site, and every guide is written against the tools themselves: each figure is computed and checked before it is published, and every linked tool is tested in the browser. More about how we work on the about page, and the full library of guides lives on the blog.