DEV Community

Cover image for How to Convert Text Case Online — camelCase, snake_case, Title Case and More
Shaishav Patel
Shaishav Patel

Posted on

How to Convert Text Case Online — camelCase, snake_case, Title Case and More

You copied text from a document and it's ALL CAPS. Or you need a variable name in snake_case but your notes are in plain sentences. Or a heading needs Title Case but you have 40 of them.

Convert any text to any case instantly, free: Case Converter — Free, No Upload


How to Convert Text Case

  1. Go to the Case Converter
  2. Paste your text into the input box
  3. Click the case format you want
  4. Copy the converted output

Converts instantly — no button delay, no page reload.


Case Formats Supported

UPPERCASE — every character in capitals. hello world → HELLO WORLD

lowercase — every character in lowercase. HELLO WORLD → hello world

Title Case — first letter of each word capitalized. hello world → Hello World

Sentence case — first letter of the first word capitalized, rest lowercase. HELLO WORLD → Hello world

camelCase — no spaces, each word after the first starts with a capital. hello world → helloWorld. Used in JavaScript variables, JSON keys, and most programming languages.

PascalCase — like camelCase but the first word is also capitalized. hello world → HelloWorld. Used for class names in most languages.

snake_case — words joined by underscores, all lowercase. hello world → hello_world. Used in Python, Ruby, database column names, and file names.

kebab-case — words joined by hyphens, all lowercase. hello world → hello-world. Used in CSS class names, HTML attributes, and URL slugs.

SCREAMING_SNAKE_CASE — snake_case in all caps. hello world → HELLO_WORLD. Used for constants in many languages.


When Each Case Is Used

Case Common use
camelCase JavaScript/TypeScript variables and functions
PascalCase Class names, React components
snake_case Python variables, database columns, file names
kebab-case CSS classes, HTML IDs, URL slugs
SCREAMING_SNAKE_CASE Constants (JS, Python, Java)
Title Case Blog post titles, headings, book titles
Sentence case Normal writing, UI labels
UPPERCASE Acronyms, emphasis, constants in some languages

Common Use Cases

Fixing copied text — Text copied from PDFs or older documents often comes in ALL CAPS or random casing. Paste and convert to sentence case in one click.

Generating variable names — Write your variable name in plain English, paste it in, convert to camelCase or snake_case. Faster than typing the formatted version from scratch.

URL slug generation — Convert a blog post title to kebab-case for use in the URL. My First Blog Post → my-first-blog-post.

Database column naming — Convert a field description to snake_case before adding it to a schema.

Heading consistency — Paste all your article headings at once and convert to Title Case. Fix 20 headings in one step instead of one at a time.

CSS class names — Convert component names from PascalCase (React) to kebab-case (CSS). UserProfileCard → user-profile-card.


Is My Text Sent to a Server?

No. All conversion happens in your browser using JavaScript. Your text never leaves your device.


Related Text Tools


Convert your text case now — free, instant, no upload: Case Converter

Top comments (0)