Developer & PM Utility

Text Case Converter

Convert any text between camelCase, PascalCase, snake_case, kebab-case, and more — all at once.

CaseResult
camelCase
PascalCase
snake_case
kebab-case
CONSTANT_CASE
Title Case
Sentence case
lowercase
UPPERCASE

Convert text between naming conventions

Every language and style guide seems to prefer a different naming convention — JavaScript variables use camelCase, Python and database columns often use snake_case, CSS classes and URL slugs use kebab-case, and constants use CONSTANT_CASE. This tool converts freely between all of them, and also handles already-mixed input (like some-Variable_name Here) by intelligently splitting on case boundaries, hyphens, underscores, and spaces.

Typical use cases

  • Renaming across a codebase: Convert a variable or field name to match a different language's convention when porting code.
  • Database & API field mapping: Quickly convert a JSON field's camelCase name to the snake_case column name your database uses.
  • URL slugs & CSS classes: Turn a page title into a kebab-case URL slug.
  • Environment variables: Convert a config key into CONSTANT_CASE for a .env file.

Which convention goes where

ContextConvention
JavaScript/TypeScript variables, functionscamelCase
JavaScript/TypeScript classes, componentsPascalCase
Python/Ruby variables, functionssnake_case
Database columns and table namessnake_case
URLs, slugs, CSS classeskebab-case
Constants, environment variablesCONSTANT_CASE

For the reasoning behind each of these and the trickier edge cases (like acronyms), see our practical guide to naming conventions.

Frequently Asked Questions

Yes — the word-splitting logic detects transitions like an all-caps run followed by a capitalized word (e.g. XMLHttp splits into XML and Http), which is how most real-world case converters handle acronyms.
Yes — underscores, hyphens, dots, and spaces are all treated as word boundaries, so converting already-formatted text works correctly in either direction.
Yes, all nine conversions update automatically as you type or paste text.
Mostly historical — JSON originated alongside JavaScript, where camelCase is the standard convention for object properties. Some APIs with Python or Ruby backends use snake_case instead, matching that language's own convention.
They're identical except for the very first letter: camelCase starts lowercase (userName), PascalCase starts uppercase (UserName). Most languages that use camelCase for variables use PascalCase specifically for class and type names, which creates a useful visual distinction between the two.