Vale CMS Need more than a rule playground? Explore

Case Converter

Type or paste text to see it in sentence case, title case, uppercase, and lowercase, and as camelCase, snake_case, and kebab-case. Copy the one you need.

For writing

Punctuation and line breaks are kept.

Sentence case

Body text, and headings in most documentation

Your text here

Title Case

Headlines and titles, in AP style

Your Text Here

Capitalized Case

Every word, including the short ones

Your Text Here

UPPERCASE

Labels and acronyms

YOUR TEXT HERE

lowercase

Undoing caps lock; tags and handles

your text here

aLtErNaTiNg

Mockery

yOuR tExT

For code

Each line becomes one name. Punctuation is dropped.

camelCase

Variables in JavaScript, Java, and Go

yourTextHere

PascalCase

Classes and types

YourTextHere

snake_case

Python and Ruby names, database columns

your_text_here

CONSTANT_CASE

Constants and environment variables

YOUR_TEXT_HERE

kebab-case

URLs, file names, and CSS classes

your-text-here

dot.case

Configuration keys

your.text.here

Runs in your browser. Your text is never uploaded or stored on a server.

Which case to use

Sentence case is ordinary writing: a capital at the start of each sentence and on proper nouns. It is also the heading style of most software documentation. Title case is for headlines and the titles of books and articles. Uppercase reads as shouting in running text and is harder to read at length, so keep it for short labels and acronyms.

Title case has more than one definition. This page uses AP’s. To compare AP, APA, Chicago, and MLA on the same headline, use the title case converter.

Naming conventions in code

  • camelCase: variables and functions in JavaScript, Java, and Go.
  • PascalCase: classes, types, and components.
  • snake_case: Python and Ruby names, and database columns.
  • CONSTANT_CASE: constants and environment variables.
  • kebab-case: URLs, file names, and CSS classes.
  • dot.case: configuration keys.

The converter reads any of these as input. It splits a name at spaces, hyphens, underscores, and dots, and where a lowercase letter meets a capital, so one list can be moved from any convention to any other.

What the converter can’t know

Sentence case can’t tell that “python” should be “Python” or that “paris” is a city. It keeps the capitals you typed on names such as “iPhone,” but where the text arrives in capitals, proper nouns come out lowercase and need a pass by hand.

Keep capitalization consistent everywhere

Converting one line is easy. Keeping every heading in a set of docs in the same case is not. Vale checks each heading against the style you pick and flags the ones that drift. To see what each guide asks for, browse the style guide explorer.

Questions

How do I change uppercase to lowercase without retyping?
Paste the text and copy the lowercase or sentence case result. Sentence case is usually what you want after leaving caps lock on: it lowercases everything, then capitalizes the first word of each sentence and the word “I.”
What is the difference between sentence case and title case?
Sentence case capitalizes only the first word and proper nouns, as in an ordinary sentence. Title case capitalizes every important word and leaves short function words such as “a,” “of,” and “to” lowercase. Capitalized case is simpler still: every word gets a capital, with no exceptions.
What are camelCase, PascalCase, snake_case, and kebab-case?
Ways of writing a name of several words where spaces are not allowed. camelCase joins the words and capitalizes each one after the first. PascalCase capitalizes the first as well. snake_case joins lowercase words with underscores, and kebab-case joins them with hyphens. CONSTANT_CASE is snake case in capitals.
Can I convert camelCase to snake_case?
Yes. The converter splits a name where a lowercase letter meets a capital, so “userAccountId” becomes “user_account_id,” and it keeps a run of capitals together, so “parseHTTPResponse” becomes “parse_http_response.” Paste several names, one per line, to convert a list.
Does it keep names like iPhone and NASA?
In sentence case and capitalized case, a word with a capital after its first letter, such as iPhone or GitHub, is left as typed, and so is an acronym standing alone in capitals. Two or more words in capitals side by side are treated as caps lock and re-cased.
Is my text uploaded?
No. The conversion happens in your browser as you type, and nothing is sent to a server.