Camel Case to Snake Case Converter
Split identifiers and phrases across acronym, camel-case, separator, and digit boundaries, then copy six deterministic naming styles.
Privacy: your files never leave your device. All processing happens locally in your browser.
How to use
- 1.Paste an identifier or phrase.
- 2.Review how acronyms, digits, and separators were tokenized.
- 3.Choose snake, kebab, camel, Pascal, constant, or title output.
- 4.Copy the value and run project-specific rename and compatibility checks.
About Camel Case to Snake Case Converter
Camel Case to Snake Case Converter turns an identifier or short phrase into six common naming styles from one deterministic token list. Paste camelCase, PascalCase, acronym-heavy names, words separated by punctuation, or a mixed phrase. The tool separates lower-to-upper transitions, keeps acronym boundaries such as XML plus Http understandable, replaces other separators with spaces, normalizes tokens to lowercase, and then assembles snake, kebab, camel, Pascal, constant, and title outputs. Every result is visible at once and has its own copy control.
Tokenization is the most important part of a case converter. Simply inserting an underscore before every capital letter would turn XMLHttpRequest into x_m_l_http_request. This implementation first separates a lowercase letter or digit followed by an uppercase letter, then separates a capital sequence before the capitalized word that follows it. Non-letter and non-number runs become boundaries. The approach preserves Unicode letters and numbers, but case conversion uses an explicit English locale so results remain stable across browsers configured with different user locales.
The six outputs serve different conventions. snake_case uses lowercase words joined by underscores. kebab-case uses hyphens. camelCase keeps the first token lowercase and capitalizes later tokens. PascalCase capitalizes every token. CONSTANT_CASE uppercases the underscore form. Title Case adds spaces and initial capitals for display-oriented labels. These are mechanical forms, not universal style rules. Languages, frameworks, databases, APIs, and teams may impose additional restrictions on leading digits, reserved words, maximum length, or accepted characters.
The converter does not transliterate scripts, singularize words, spell-check text, preserve punctuation, or guess semantic abbreviations. For example, user ID may become userId rather than a project-specific userID. Review acronym policy before renaming public symbols. Changing an exported identifier, database column, environment variable, URL, or JSON property can be a breaking change even when the new spelling looks cleaner. Use search, type checking, migrations, compatibility aliases, and tests appropriate to the system being changed.
Input is capped at five thousand code units to keep rendering and clipboard operations bounded. Empty or punctuation-only input is rejected because it contains no convertible token. Digits remain within tokens where boundaries permit. Whitespace and repeated separators collapse rather than producing empty words. The converter displays plain text through React and does not execute pasted content. Still, do not paste secrets, API keys, private source code, or personally identifying data into tools unless your organization permits local processing.
Everything runs in the browser and nothing is uploaded or stored. No login or package is required. The transformations are an explicit product policy rather than a claim that one naming style is correct. Copy the result that matches your codebase, then run formatters, linters, type checks, tests, and repository-wide reference updates. For public APIs or persisted fields, plan backward compatibility before adopting the renamed value. File systems and databases may compare identifiers with different case-sensitivity rules, so a rename that differs only by capitalization can need an intermediate name. Generated code, reflection, configuration, templates, and external consumers may also contain references that language-aware rename tools cannot discover. Review diffs and deployment order before merging a broad rename.
Methodology & sources
Splits lower-or-digit to uppercase transitions and acronym-to-capitalized-word boundaries, converts other separator runs to boundaries, applies stable English-locale casing, and assembles six disclosed naming policies.
Frequently asked questions
- Why does XMLHttpRequest become xml_http_request?
- The tokenizer separates an acronym before the capitalized word that follows it instead of splitting every capital into a separate token.
- Does this safely rename code across a project?
- No. It only transforms text. Use language-aware rename tools, search, migrations, type checks, and tests for real code changes.
- Will it preserve punctuation?
- No. Punctuation and separator runs become word boundaries. The output styles contain only letters, numbers, and their selected joiner.
Related tools
- Regex TesterTest JavaScript regex live β see every match, capture group, and named group highlighted as you type.
- JSON FormatterFormat, minify, and validate JSON in your browser β pretty-print or compress with pinpoint error locations.
- ANSI Color Codes GeneratorBuild and copy raw SGR escape sequences and search the standard 8 plus bright 8 terminal color codes.
- ASCII TableLook up every standard 7-bit ASCII code with exact decimal, hexadecimal, octal, and binary values.
- Badge GeneratorBuild a Shields.io badge URL, Markdown snippet, and HTML image tag without memorizing path escapes or query parameters.
- BOM RemoverRemove exactly one leading U+FEFF from pasted decoded text locally while preserving every internal, trailing, or second leading occurrence.
Developer Tools guides
View all- How to Get a CSS Loader With a Visual Generator
- Make a CSS Grid in Minutes with a Live Generator
- Create a Linear Gradient in Canva Using CSS Gradient Generator
- Convert a Cake Recipe to Cookies Using a Cookie to JSON Tool
- Create Glassmorphism Effects in CSS with a Visual Generator
- Design Custom CSS Shapes with a Free Clip Path Generator
- Create a 3D Button in CSS with a Visual Generator
- How to Get a Box Shadow in CSS with a Visual Generator
- Border Radius Generator Online: Copy the Shortest CSS Declaration
- Parse a Cron Expression and See Next Run Times Instantly
- How to View the Clipboard and Inspect Hidden Text Details
- How to Get Badge Elevators in NBA 2K25 Using a Badge Generator
- How to Generate Code Image From Text Locally
- Calculate Chmod Values Quickly Using Octal and Symbolic Notation
- Remove BOM from CSV Files Without Losing Data
- How to Use ASCII Codes in C++ for Character Handling
- Build a Cron Job Schedule Without Memorizing Field Order
- How to Create Flexbox in CSS: A Practical Walkthrough
- Create a Dummy File in CMD with Exact Size and Content
- How to Create a Directory Tree in CMD: A Practical Walkthrough