JSON Key Case Converter
Rename every key in a JSON document to camelCase, snake_case, kebab-case or PascalCase, at every depth or only the top level, without touching values.
Free · No sign-up · Your inputs stay in your browser
Input
Convert JSON keys between camelCase and snake_case
Output
Converted JSON
241 characters
Only keys change; values, including strings that look like identifiers, are left alone. Two keys that collapse to the same name (user_id and userId) keep the later one, so check the key count when a payload mixes conventions.
Runs in this browser. Nothing you paste is sent to a server.
About this tool
Method, assumptions, practical next steps, and limits.
Where the conventions meet
Ruby, Python, PHP and SQL columns favour snake_case; JavaScript and most JSON APIs designed for browsers use camelCase. Converting at the boundary, once, keeps each side idiomatic. Laravel API resources usually do it with Str::camel(); in JavaScript, a small recursive function or a library such as camelcase-keys does the same thing as this tool.
Collisions
If a payload already mixes conventions, user_id and userId both become userId, and only the later value survives. Check the key count before and after on unfamiliar data.