Snake Case Converter
Convert text to snake_case format for Python and databases
Free, no signup — converted in your browser, never uploaded.
TextSample
31 charactersEach line converts on its own
snake_case
convert_ this_ text_ to_ snake_ case
Other developer formats
- kebab-caseconvert-
this- text- to- snake- case - camelCaseconvert
This Text To Snake Case - PascalCaseConvert
This Text To Snake Case
What is Snake Case?
Snake case is a naming convention where spaces are replaced with underscores and all letters are lowercase. For example, "my variable name" becomes "my_variable_name".
It gets its name because the underscores resemble a snake lying on the ground.
When to Use Snake Case
- Python: The standard convention for variable names and function names (PEP 8)
- Database columns: Common in SQL database schemas
- File names: Often used for configuration files
- Ruby: Standard naming convention for methods and variables
- C/C++: Sometimes used for constants and macros
Snake Case vs Other Conventions
| Convention | Example | Common Use |
|---|---|---|
snake_case | user_name | Python, Ruby, databases |
camelCase | userName | JavaScript, Java |
PascalCase | UserName | C#, class names |
kebab-case | user-name | URLs, CSS classes |