--- id: camel-converter version: "5.1.0" license: MIT License Copyright (c) 2021 Paul Sanders Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal… (full text in the JSON record) license_treatment: permissive maintenance: active --- # camel-converter — Converts a string from snake case to camel case or camel case to snake case License: permissive · Maintenance: active · Downloads: 1.9M/mo ## What it is and what it does Camel Converter is a lightweight utility for transforming naming conventions between camelCase (used in JSON and JavaScript), snake_case (Python convention), and PascalCase. It operates on individual strings, dictionary keys, and class attributes, making it useful when bridging Python code with external APIs or data formats that use different naming standards. The package provides standalone functions (to_snake, to_camel, to_pascal), dictionary converters (dict_to_snake, dict_to_camel, dict_to_pascal), decorators for automatic conversion on function return values, a base Converter class for adding conversion methods to custom classes, and an optional Pydantic integration (via the pydantic extra) that automatically handles case conversion in model serialization and deserialization. Use it for: - Parse JSON APIs that use camelCase keys into Python objects with snake_case attributes - Convert Python dictionaries with snake_case keys to camelCase for JSON serialization to external services - Decorate functions that return dictionaries to automatically normalize key naming conventions - Build Pydantic models that accept camelCase input data and expose snake_case fields internally - Create custom classes that serialize to camelCase while maintaining snake_case in Python code ## Worth the install? AI-flagged interpretation of the facts above — verify before relying. Converts strings and dictionary keys between camelCase, snake_case, and PascalCase formats, with optional decorator and Pydantic integration. Yes. Zero runtime dependencies, permissive MIT license, active maintenance, and broad Python version support (3.10–3.14) make this a safe, low-friction addition. Install it when you need to bridge naming conventions between Python and external APIs or JSON data—the common case for web services and data integration work. ## Install pip install camel-converter uv add camel-converter poetry add camel-converter ## Installing camel-converter Before you install: Low friction install with no runtime dependencies. Actively maintained as of 2026-03-05, marked Production/Stable, and supports current Python versions from 3.10 through 3.14. License in practice: MIT License permits free use, modification, and distribution with minimal restrictions—suitable for both open-source and commercial projects. Quickstart: pip install camel-converter from camel_converter import to_snake, to_camel snake = to_snake("myString") # 'my_string' camel = to_camel("my_string") # 'myString' Verify before relying: - Behavior when handling acronyms or consecutive uppercase letters (e.g., 'HTTPServer' → 'http_server' or 'h_t_t_p_server') - Performance characteristics with deeply nested dictionaries or very large key sets - Whether the optional Pydantic extra is compatible with Pydantic v2 ## Package facts - License: MIT License Copyright (c) 2021 Paul Sanders Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal… (full text in the JSON record) (permissive) - Python support: supports_current - Install friction: low - Maintenance: active - Downloads: 1.9M/month (top 5,000 on PyPI) - Known vulnerabilities: none known ## Tags camel case to snake case converter, snake case to camel case, json key naming convention, case conversion utilities, dictionary key transformation, pydantic camel case, string case conversion, json-interop, naming-conventions [View on SkillFed](https://skillfed.io/packages/camel-converter) · [View on PyPI](https://pypi.org/project/camel-converter/)