Text Case Converter & Cleanup Tool
Convert text to the right case format, remove duplicates and blank lines, and clean messy pasted content locally in your browser.
Your text stays private. Everything is processed locally in your browser. Nothing is uploaded to a server. Safe for internal notes, drafts, emails, logs, and sensitive code snippets.
All text processing happens locally in your browser using JavaScript string operations. Nothing is uploaded to CodeAva servers and nothing is stored between sessions. Safe for internal drafts, customer data, sensitive logs, proprietary copy, and any text you cannot share with an external service.
Why text case conversion and cleanup matter
Text arrives in the wrong format constantly. Content pasted from Google Docs, Notion, Confluence, or a spreadsheet export rarely matches the target format. Headings arrive in all caps. Developer variable names need converting from a phrase. Email lists come back with duplicate entries and trailing spaces. Published copy needs proper title capitalisation before it goes live.
Developers, writers, marketers, and operations teams all hit these friction points daily. Editorial teams need Title Case and Sentence case for headings and copy. Developers need camelCase, snake_case, and kebab-case for variable names, API keys, and URL slugs. Data teams need clean, deduplicated line lists. Everyone needs whitespace to behave.
Processing this kind of text locally matters for privacy. Internal notes, customer names, draft copy, log snippets, and configuration strings are all common inputs for text utilities. Sending them to a third-party formatting server introduces unnecessary risk. This tool handles everything within your browser tab — the text never leaves your device.
What is the difference between Title Case and Sentence case?
Title Casecapitalises the first letter of most major words in a heading or title. Short connector words — such as “and,” “the,” “in,” and “of” — are left lowercase unless they appear at the start or end of the title. Different editorial style guides (AP, Chicago, APA) have slightly different rules; this tool uses a practical common-sense ruleset that covers the majority of everyday use cases.
Sentence case capitalises only the first word of the sentence and any proper nouns, making it closer to normal prose formatting. It is commonly used in subheadings, UI labels, and editorial environments that prefer a less formal register. The key distinction: Title Case is for titles and headings. Sentence case is for sentences and conversational copy.
Developer formatting: camelCase, snake_case, kebab-case, and more
Different programming languages and ecosystems have strong naming conventions. Using the wrong format in code can break linters, fail API schema validation, or create inconsistencies in a codebase. Here is a quick reference:
| Format | Example | Common use case |
|---|---|---|
camelCase | myVariableName | JavaScript/TypeScript variables and functions |
snake_case | my_variable_name | Python, Ruby, database column names, JSON keys in some APIs |
kebab-case | my-variable-name | URL slugs, HTML attributes, CSS custom properties, CLI flags |
PascalCase | MyVariableName | React components, TypeScript classes, C# types |
CONSTANT_CASE | MY_CONSTANT_NAME | Environment variables, configuration constants, enum members |
Common text cleanup patterns
For automated pipelines or scripting environments, here are common cleanup patterns — and where the browser tool is a better choice.
Remove duplicate lines (regex, most editors and tools)
^(.+)(\n\1)+$ → $1 (multiline, with "find all" deduplicate support)
// In JavaScript:
const unique = [...new Set(text.split("\n"))].join("\n");Collapse multiple spaces (JavaScript)
const cleaned = text.replace(/[ \t]+/g, " ");
Strip HTML tags — browser tool vs regex
// Simple tag removal — works for plain pasted content: const stripped = html.replace(/<[^>]+>/g, ""); // Note: regex is not a safe HTML parser for complex or // untrusted HTML. For production sanitization use a // dedicated library (e.g. DOMPurify, sanitize-html).
For one-off pasted content cleanup, the CodeAva tool's HTML strip option is safe and practical. For production sanitization of untrusted HTML, use a dedicated library.
What this tool helps with
Good uses
- Converting titles and headings for publishingpaste a heading in any format and convert to Title Case or Sentence case before publishing to CMS, email, or social.
- Normalising developer naming conventionsconvert phrases into camelCase, snake_case, kebab-case, or CONSTANT_CASE for variable names, API keys, environment variables, and URL slugs.
- Cleaning email lists or line-based exportsremove duplicate entries, trim whitespace, and strip blank lines from exported CSV or copy-pasted lists.
- Stripping HTML from pasted web contentremove tags from content pasted from web pages, documentation, or rich-text editors before processing.
- Preparing copy for spreadsheets and importsnormalise casing and clean whitespace before importing into spreadsheets, CRMs, or databases.
- Formatting log output and documentation snippetsclean up copied log lines, README content, or pasted API documentation for readability.
Limitations to know
- Smart Title Case for every editorial style guidethis tool uses a practical common-sense ruleset. For AP, Chicago, or APA compliance, review output for edge cases like brand names and acronyms.
- Complex HTML parsingthe HTML strip feature removes tags from simple pasted content. For production sanitization of untrusted HTML, use a dedicated library like DOMPurify.
- Preserving Unicode or RTL text perfectlycase conversion is based on standard Unicode letter transforms. Right-to-left scripts and some non-Latin alphabets may not convert predictably.
- Duplicate removal with fuzzy matchingduplicate-line removal matches exact strings only. Enable 'Trim spaces' first to normalise lines before deduplication if spacing varies.
How to use the Text Case Converter & Cleanup Tool
- 1
Paste text into the input area
Type or paste any text. Live stats show character count, word count, line count, and byte size in real time as you type.
- 2
Choose a case format
Click any format button in the Case format panel. Editorial formats include UPPERCASE, lowercase, Title Case, and Sentence case. Developer formats include camelCase, PascalCase, snake_case, kebab-case, and CONSTANT_CASE. The output updates immediately.
- 3
Enable cleanup options if needed
Toggle any combination of cleanup options: remove duplicate lines, trim whitespace, collapse spaces, remove blank lines, or strip HTML tags. Click 'Apply cleanup' to run them.
- 4
Review the output and status message
The output panel shows the transformed text. A status message describes exactly what was changed — e.g. 'Converted to camelCase · Removed 12 duplicate lines'.
- 5
Copy or download the result
Use the Copy button to copy output to your clipboard, or click .txt to download the result as a plain text file.
Common issues and how to fix them
Pasted text has inconsistent or extra spaces between words
Enable 'Collapse repeated spaces' in the cleanup options and click Apply cleanup. This reduces any sequence of spaces or tabs to a single space.
Duplicate lines remain after deduplication
Duplicate-line removal is exact-match only. Lines that look identical but differ in leading/trailing spaces will not be detected as duplicates. Enable 'Trim leading/trailing spaces' before running deduplication.
Title Case capitalises words that should stay lowercase
Smart Title Case uses a common-sense minor-word list (and, the, in, of, etc.). Brand names, product names, and acronyms that coincidentally match minor words may be lowercased. Review output for these cases and adjust manually.
HTML content still shows tags after strip
The HTML strip removes standard < > tags. Self-closing tags and standard HTML are handled correctly. If tags remain, they may use unusual whitespace or encoding. Inspect the raw input and check for HTML entities like < which are text content rather than actual tags.
Developer case output looks wrong for mixed-punctuation input
Developer formats (camelCase, snake_case etc.) normalise the input by splitting on spaces, hyphens, underscores, and CamelCase boundaries before reassembling. Sentences with punctuation like commas, apostrophes, or parentheses may produce unexpected splits. Clean the input first or convert it line by line.
Sentence case lowercases proper nouns
Sentence case capitalises only the first word and applies lowercase to the rest. Proper nouns and brand names will be lowercased unless they begin the sentence. This is by design — review output and restore capitalisation for proper nouns manually.