About This Tool
Convert variable names, database fields, and configuration keys to snake_case. The tool recognizes separators, case boundaries, and acronyms: helloWorld becomes hello_world, and XMLHttpRequest becomes xml_http_request.
How to Use It
- Enter a name or a list of field names on separate lines.
- Choose whether to convert each line independently; this is on by default.
- Click Convert and check the lowercase words and single underscores.
- Copy or download the output, then verify identifier validity in the target language.
Examples
- Hello World → hello_world; helloWorld → hello_world.
- XMLHttpRequest → xml_http_request.
- multiple spaces → multiple_spaces; Café Name → café_name.
Rules and Limits
Words are recognized from changes in letter case, acronyms, and common separators. Unicode-aware casing lowercases each word, which is then joined with a single underscore. Repeated separators do not create repeated underscores, and Chinese characters or other Unicode letters are not removed by an ASCII-only filter.
Common Uses
- Organize Python variables or database columns.
- Standardize configuration keys.
- Convert camelCase properties in batches.
Privacy
Your text, files, and previews are processed in your browser. Your input is never uploaded or automatically saved. Save anything you need to keep before leaving the page.
FAQ
What is snake_case?
Words are separated by underscores and are usually lowercase, as in user_name.
Can it convert existing camelCase?
Yes. Case boundaries split words, so helloWorld becomes hello_world.
Will multiple spaces produce multiple underscores?
No. Consecutive separators become word boundaries, and output uses just one underscore between adjacent words.
Are Chinese characters removed?
No. They are preserved, with underscores between explicitly separated words. The tool does not perform Chinese semantic segmentation or translation.