Examples:
user_id → user-id
first_name → first-name
total_amount_calculated → total-amount-calculated
api_response_data → api-response-data
is_active_flag → is-active-flag
How to Use This Tool
Our Snake Case to Kebab Case Converter is simple to use:
- Type or paste your snake_case text in the input box
- Click the "Convert to kebab-case" button
- Copy the converted result from the output box
What is snake_case and kebab-case?
snake_case is a naming convention where words are separated by underscores (_). It's commonly used in Python, Ruby, and database column names.
kebab-case (also called hyphen-case) is a naming convention where words are separated by hyphens (-). It's widely used in HTML attributes, CSS classes, and URL slugs.
Why Convert Between Naming Conventions?
Different technologies use different conventions. You might need to convert between these styles when:
- Converting database column names to HTML attributes
- Mapping Python variables to CSS class names
- Creating URL slugs from database identifiers
- Working with APIs that use different naming conventions
- Enforcing consistent style guides across projects
Common Use Cases
- Converting Python variable names to CSS class names
- Generating URL slugs from database identifiers
- Creating HTML data attributes from backend variables
- Normalizing naming conventions across frontend and backend
- Preparing JSON data for web applications
Technical Details
This converter handles all edge cases including:
- Multiple consecutive underscores
- Leading/trailing underscores
- Mixed case input (converts to lowercase)
- Multiple lines or comma-separated values