Case Converter
Change text to sentence case, UPPERCASE, lowercase, Title Case, camelCase, snake_case, kebab-case, and PascalCase instantly.
Case conversion tools transform text between naming conventions used across programming languages, frameworks, and style guides.
Convert your text case
Paste your text, choose a case style, and copy the converted result in one click.
Choose case style
Characters: 0 • Words: 0
Related tools
Useful next steps for formatting, writing, and SEO.
Supported Case Types
| Type | Example | Primary Use |
|---|---|---|
| camelCase | myVariableName | JavaScript, Java variables |
| PascalCase | MyClassName | Class names, React components |
| snake_case | user_profile_data | Python, Ruby, database columns |
| kebab-case | user-profile-data | URLs, CSS classes, file names |
| SCREAMING_SNAKE_CASE | API_BASE_URL | Constants, environment variables |
| dot.case | user.profile.data | Object paths, config keys |
| Train-Case | User-Profile-Data | HTTP headers, occasionally titles |
| Title Case | User Profile Data | Headings, article titles |
Common Use Cases
API response transformation: Backend APIs often return data in snake_case (Python/Django standard), but JavaScript frontends expect camelCase. Converting 200+ response fields manually is error-prone. Use this tool to batch convert field names, then run find-and-replace in your codebase.
Database column refactoring: Migrating from legacy camelCase column names to PostgreSQL-standard snake_case. Real example: converting 47 columns from PascalCase to snake_case during a schema migration. Generate the list, convert it, then use the output to write ALTER TABLE statements.
CSS class naming: Moving from an inconsistent naming scheme to BEM or Tailwind conventions. Convert component names from PascalCase to kebab-case for class names. Works well when refactoring React components that use CSS modules.
Environment variable creation: Taking feature flags or config keys and converting them to SCREAMING_SNAKE_CASE for .env files. Standard across Docker, Kubernetes, and most deployment platforms.
URL slug generation: Converting article titles or page names to kebab-case for clean URLs. Works alongside the dedicated slug generator for more complex transformations that require additional sanitization.
Code review standardization: Team switches to a new style guide (Airbnb, Google). Batch convert variable names in a file, then review changes. Faster than manual fixes, though full automation requires IDE refactoring tools.
GraphQL schema conversion: GraphQL uses camelCase for field names. If your database or ORM uses snake_case, you need consistent field name mapping. Convert schema definitions in bulk to match your resolver layer.
Multi-language codebases: Working across Python backend (snake_case) and TypeScript frontend (camelCase). Keep a reference list of field mappings by converting between conventions as data crosses the API boundary.
Built by Tyler - a dev who got tired of manual find-and-replace for case conversions across codebases.
Language-Specific Conventions
JavaScript/TypeScript: Variables and functions use camelCase, classes use PascalCase (Airbnb Style Guide, Google JavaScript Style Guide).
Python: Functions and variables use snake_case, classes use PascalCase (PEP 8).
Ruby: Methods and variables use snake_case, classes and modules use PascalCase (Ruby Style Guide).
Java: Variables and methods use camelCase, classes use PascalCase (Oracle Java Conventions).
C#: PascalCase for public members, camelCase for private fields (Microsoft C# Naming Guidelines).
Go: Exported identifiers use PascalCase, unexported use camelCase (Effective Go).
Rust: snake_case for variables and functions, PascalCase for types (Rust API Guidelines).
PHP: camelCase or snake_case depending on framework; Laravel uses snake_case, Symfony uses camelCase.
CSS/HTML: kebab-case for class names and IDs (BEM methodology).
SQL: snake_case for table and column names (PostgreSQL conventions).
Batch Processing
The converter handles multi-line input. Paste a list of identifiers (one per line) and convert all at once. Line breaks are preserved, so the output maintains the same structure as the input.
Special characters outside standard alphanumeric ranges are preserved where possible. Numbers are kept in place. Underscores and hyphens are interpreted as word boundaries for splitting, then reconstructed based on the target case.
Edge cases: Unicode letters are handled by JavaScript string methods, so most accented characters work correctly. Emoji and other non-letter symbols pass through unchanged but may affect word boundary detection. For production code refactoring, test on a small sample first.
The tool works best with identifiers under 100 characters. Extremely long strings (1000+ chars) may behave unpredictably with complex Unicode. For large datasets or full file processing, use command-line tools or IDE refactoring features instead.
Implementation Notes
The converter uses regex patterns to detect word boundaries: camelCase humps, underscores, hyphens, dots, and spaces. Text is first normalized to lowercase words, then reconstructed according to the target case rules.
Limitations: Acronyms are not preserved (API becomes api in intermediate steps). Complex mixed-case strings may lose intentional capitalization. Does not handle language-specific rules like German nouns or French accents.
Character encoding: Assumes UTF-8. Non-ASCII characters are supported but may not split correctly if they include letter-like symbols that JavaScript regex does not recognize as word boundaries.
Performance: Runs entirely client-side using simple string operations. Handles up to several thousand characters without lag. Processing time is linear with input length. No server round trip means conversions are instant.
Style Guide Resources
- MDN Web Docs - Naming conventions for web development
- Google Style Guides - Multi-language style references
- PEP 8 - Python style guide with naming rules
- Airbnb JavaScript - Popular JavaScript conventions
- Effective Go - Official Go naming guidelines
FAQ
Does this preserve special characters?
Most special characters are preserved. The tool focuses on letter case and word boundaries. Numbers and common symbols pass through unchanged.
Can I convert entire code files?
You can paste code blocks, but the tool works best on identifiers and variable names. For full file refactoring, use your IDE find-and-replace with regex.