Skip to content

Text Case Converter

Convert text to UPPERCASE, lowercase, Title Case, Sentence case, camelCase, snake_case, dot.case and more, then clean it up with one-click text operations and download the result as a .txt file.

0 characters · 0 words · 0 lines · 0 sentences · 0 letters · 0 digits · 0 spaces

Case mode
Text operations

Operations clean up your text before the case mode is applied. Each click runs once.

0 characters · 0 words · 0 lines · 0 sentences

How to use the Text Case Converter

  1. Type or paste your text into the Your text box.
  2. Pick a case mode. The converted text appears instantly in the Converted text box, and the character, word, line, and sentence counts update under both boxes.
  3. Use the Text operations buttons to clean up your text before conversion: remove extra or all spaces, strip line breaks, trim, sort, dedupe, or number lines.
  4. Click Copy result to copy the converted text, Download .txt to save it as a file, Use output as input to run the result through another mode, Clear to empty both boxes, or Load sample to insert a ready-made sentence.

All conversions run in your browser, so your text never leaves the page.

What each case mode does

  • UPPERCASE: capitalizes every letter.
  • lowercase: lowercases every letter.
  • Title Case: capitalizes the main words and keeps short words such as the, of, and and lowercase unless they are the first or last word.
  • Sentence case: capitalizes the first letter of every sentence and lowercases the rest.
  • Capitalized: capitalizes the first letter of every word and lowercases the rest of each word.
  • camelCase: joins the words with no separator; the first word is lowercase and every following word starts with a capital.
  • PascalCase: same joining as camelCase but every word starts with a capital.
  • snake_case: joins lowercase words with underscores.
  • kebab-case: joins lowercase words with hyphens.
  • CONSTANT_CASE: joins uppercase words with underscores.
  • dot.case: joins lowercase words with dots.
  • URL slug: joins lowercase words with hyphens and removes accents, ideal for web addresses.
  • aLtErNaTiNg CaSe: alternates lowercase and uppercase letters.
  • InVeRsE: swaps the case of every letter.
  • Random Case: randomly capitalizes or lowercases each letter.

Text operations

The Text operations row cleans up your text before the selected case mode is applied. Each button runs once when you click it.

  • Remove extra spaces: collapses runs of spaces and tabs into single spaces.
  • Remove all spaces: deletes every space and tab.
  • Remove line breaks: joins all lines into one.
  • Trim lines: strips leading and trailing whitespace from each line.
  • Sort lines: sorts the lines alphabetically.
  • Dedupe lines: removes repeated lines and keeps the first occurrence.
  • Number lines: adds a number to the start of each line.
  • Remove empty lines: deletes blank lines.

Case conventions for developers

Starting from the sentence “The quick brown fox jumps over the lazy dog!”, the developer modes produce:

Developer case conventions and their typical uses
Mode Output Typical use
camelCase theQuickBrownFoxJumpsOverTheLazyDog JavaScript variables and functions
PascalCase TheQuickBrownFoxJumpsOverTheLazyDog Class names and React components
snake_case the_quick_brown_fox_jumps_over_the_lazy_dog Python variables and database columns
kebab-case the-quick-brown-fox-jumps-over-the-lazy-dog URL slugs and CSS class names
CONSTANT_CASE THE_QUICK_BROWN_FOX_JUMPS_OVER_THE_LAZY_DOG Environment variables and constants
dot.case the.quick.brown.fox.jumps.over.the.lazy.dog Configuration keys and namespaces
URL slug the-quick-brown-fox-jumps-over-the-lazy-dog Clean web addresses

Worked examples

1. Sentence boundaries. Type hello, world! how are you? and pick Sentence case: you get Hello, world! How are you? because the letter after the exclamation mark is capitalized. The same input becomes helloWorldHowAreYou in camelCase.

2. Punctuation and symbols. Type product_name & price (USD) and pick snake_case: you get product_name_price_usd. The ampersand, parentheses, and spaces are removed, and the words are joined with underscores.

3. Cleaning up pasted text. Paste a block with double spaces and blank lines, click Remove extra spaces and then Remove empty lines, and the text becomes tidy before you pick a case mode.

4. Accented characters. Type café au lait and pick UPPERCASE: you get CAFÉ AU LAIT. With Title Case the same input becomes Café Au Lait, and with URL slug it becomes cafe-au-lait.

Limits and notes

  • Sentence case lowercases everything except the start of each sentence, so proper nouns such as Google or iPhone are also lowercased.
  • The developer modes remove punctuation and whitespace between words, so a string like first-name becomes firstName in camelCase rather than keeping the hyphen.
  • Title Case follows the short-word rule: words such as a, an, the, of, in, and and stay lowercase unless they are the first or last word.
  • Alternating, inverse, and random case change letters only; numbers and symbols are kept exactly as typed.
  • URL slug removes accents but keeps letters and numbers, so accented characters are transliterated to their plain form.
  • The converter works offline and never uploads your text.

Related tools

More utilities you may find useful.

View all tools