Case Converter

From ToolzPedia, the free tools encyclopedia
This is one of several utilities. For the full list of utilities, see All tools.

Text case conversions are a surprisingly frequent micro-task in writing, development, and content work. A database schema written in snake_case needs converting to camelCase for a JavaScript object. A blog post title needs Title Case applied consistently. An ALL-CAPS paste from a legacy system needs to become readable text. Doing any of these by hand across hundreds of words wastes time and introduces errors.

The ToolzPedia Case Converter converts text between eight different case formats in one click: UPPER CASE, lower case, Title Case, Sentence case, camelCase, PascalCase, snake_case, and kebab-case. Paste your text, pick the target format, and copy the result. The conversion is instant, runs in your browser, and handles any length of text.

Developers will use this most for the programming-style cases (camelCase, PascalCase, snake_case, kebab-case). Writers and editors will reach for Sentence case and Title Case. System admins working with legacy all-caps data will use lower case as a first normalisation step.

Use the tool edit

How to use Case Converter edit

Follow these steps to use the tool:

  1. Enter your text

    Type or paste any text into the input box.

  2. Choose a case

    Click any of the 12 case style buttons to convert instantly.

  3. Copy the result

    Hit Copy to grab the converted text, or Use as input to chain conversions.

Frequently asked questions edit

In camelCase the first word is lowercased and subsequent words are capitalised: myVariableName. In PascalCase (also called UpperCamelCase) every word including the first is capitalised: MyClassName. camelCase is used for variables and function names in JavaScript, Java, and C#. PascalCase is used for class names, React components, and type names in TypeScript.
Kebab-case (words-joined-by-hyphens, all lowercase) is the standard convention for CSS class names, HTML custom data attributes (data-user-id), URL slugs, and npm package names. It is called kebab-case because words are skewered together by hyphens.
Python's PEP 8 style guide recommends snake_case for variable names, function names, and module names because Python code traditionally aimed for readability at the cost of brevity. SQL and database schemas use snake_case because SQL is case-insensitive and snake_case is unambiguous when the engine normalises everything to lowercase.
Yes. Each line is converted independently, preserving line breaks. Sentence case applies per-sentence within each line. This makes it useful for converting multi-paragraph pastes.

Use cases edit

Database to API conversion

Database column names are often in snake_case (first_name, order_date). JavaScript and JSON conventions use camelCase (firstName, orderDate). Convert between them instantly when writing API response formatters.

Blog and article title formatting

Style guides for publications typically require Title Case for headlines. Paste a working title in any capitalisation and convert to Title Case to get publication-ready formatting.

CSS class naming

Kebab-case (my-class-name) is the CSS convention for class names, while camelCase is used in JavaScript when referencing those classes. Convert between them when writing styles and scripts that interact.

Normalising imported data

CSV exports from older systems frequently use ALL CAPS for field values. Converting to lower case or Sentence case as a first step makes the data usable in modern interfaces.

Component and variable naming

React components use PascalCase (MyComponent), CSS modules use kebab-case (my-component), and Python variables use snake_case (my_variable). When working across multiple languages or layers, case conversion eliminates manual renaming.

How it works edit

The converter tokenises the input text into words. The definition of a word boundary differs by target case: for uppercase, lowercase, Sentence case, and Title Case, boundaries are standard whitespace and punctuation. For programming cases (camelCase, PascalCase, snake_case, kebab-case), the tokeniser also splits on existing case transitions (detecting camelCase or PascalCase input) and on underscores, hyphens, and spaces, so that whatever case format the input is in, the output is correctly formed.

Once words are identified, the transformation is applied: for UPPER CASE every character is capitalised; for lower case everything is lowercased; Title Case capitalises the first letter of every word (minor words like "a", "the", "of", "and" are lowercased in a full title-case implementation); Sentence case capitalises only the first letter of the first word and any word after a sentence-ending punctuation mark; camelCase joins words with the first word lowercase and subsequent words capitalised; PascalCase capitalises every word and joins without separator; snake_case lowercases everything and joins with underscores; kebab-case lowercases everything and joins with hyphens.

Tips and best practices edit

  • When converting to camelCase or snake_case, make sure your input separates words clearly, either with spaces, existing underscores, hyphens, or camelCase transitions. The converter detects all of these as word boundaries.
  • Title Case in English has style-guide variations: AP Style, Chicago Manual of Style, and APA all have slightly different rules about which short words to capitalise. The converter applies a widely-used standard rule set, so double-check against your specific style guide for publications with strict requirements.
  • Sentence case is the most readable case for body text and subtitles. It preserves proper nouns (assuming they were correctly capitalised in the input) and reads naturally. Use it to fix ALL CAPS pastes from legacy systems.
  • For programming cases, the converter handles multi-word input even if it is not already in a consistent case. "Hello World Example" and "hello-world-example" and "helloWorldExample" all convert correctly to any target case.

Common mistakes edit

Expecting the converter to know which words are proper nouns

The converter cannot know that "london" should be "London" or that "javascript" should be "JavaScript". If proper noun capitalisation matters, review the output after conversion.

Using Title Case for body text

Title Case is for headlines and titles only. Using it in body paragraphs is stylistically incorrect and makes text harder to read. Sentence case is correct for paragraphs, captions, and labels.

Other free utilities available on ToolzPedia:

See also edit