Convert camelCase to snake_case

Convert camelCase variable names to snake_case instantly. Essential for Python, Ruby, and database column naming. Free tool.

Example: myVariableName → my_variable_name

0 words, 0 chars
Text
Programming
Other
aa
lowercaseoutput

About This Conversion

Converting camelCase to snake_case is a common task when working across programming languages. JavaScript and Java use camelCase (myVariableName), while Python, Ruby, and SQL databases prefer snake_case (my_variable_name). This tool intelligently detects word boundaries at uppercase letters and inserts underscores. It handles edge cases like consecutive capitals (XMLParser → xml_parser), numbers (item2Count → item2_count), and already-underscored text. Essential for API field mapping, database migration, and code style conformance.

Frequently Asked Questions

When should I use snake_case?
Python (PEP 8 standard), Ruby, Rust, database column names, environment variables, and file names on Linux systems all typically use snake_case.
How does the tool handle consecutive uppercase letters?
Consecutive capitals like 'XMLParser' are converted to 'xml_parser' — the tool detects where the acronym ends and inserts the underscore before the next lowercase letter.
Can I convert an entire file of variable names?
Yes. Paste multiple lines — each variable name will be converted independently. The tool preserves line breaks so you can convert a list of identifiers at once.

Related Case Conversions