--- id: textcase version: "0.4.5" license: MIT license_treatment: permissive maintenance: active --- # textcase — Python library for text case conversions. License: permissive · Maintenance: active · Downloads: 125.7K/mo ## What it is and what it does textcase is a pure-Python library for converting strings between different text case formats—snake_case, kebab-case, camelCase, PascalCase, CONSTANT_CASE, and others. It handles word boundary detection automatically, including acronyms (e.g., "HTTPRequest"), non-ASCII characters, and punctuation, without requiring regex or external dependencies. The library is fully type-annotated and carries 100% test coverage. You import it and call functions like `textcase.snake()`, `textcase.camel()`, or `textcase.pascal()` on any string. It's useful when you need to normalize identifiers across different naming conventions—for instance, converting API response field names to Python variable names, or generating code identifiers from user input. With zero dependencies and a small footprint, it's safe to add to any project. Use it for: - Convert API response field names (often snake_case) to camelCase for JavaScript or PascalCase for C# - Generate valid Python variable or function names from user-provided strings or external data - Normalize configuration keys or environment variable names across different naming conventions - Transform database column names to match code style conventions in ORM or data mapping layers - Build code generators or template systems that need to adapt identifiers to target language conventions ## Worth the install? AI-flagged interpretation of the facts above — verify before relying. Converts strings between different text case formats (snake_case, kebab-case, camelCase, PascalCase, etc.) with support for non-ASCII characters and custom word boundaries. Yes. textcase is lightweight (zero dependencies), actively maintained, well-tested, and solves a common string-manipulation task cleanly. Install it if you need reliable case conversion; the low friction and permissive license make it a safe addition to any project. ## Install pip install textcase uv add textcase poetry add textcase ## Installing textcase Before you install: Low friction: pure Python wheel with zero runtime dependencies and active maintenance. Last commit 2026-08-08, 236 repository stars, and 125731 monthly downloads indicate steady adoption. License in practice: MIT license (permissive) means you can use, modify, and distribute this package freely in both open-source and commercial projects with minimal restrictions. Quickstart: pip install textcase import textcase textcase.snake("Hello, world!") # hello_world textcase.camel("Hello, world!") # helloWorld textcase.pascal("Hello, world!") # HelloWorld Verify before relying: - Whether the library's handling of acronyms and non-ASCII boundaries covers all real-world edge cases beyond the documented examples - Performance characteristics when processing very large strings or high-volume batch conversions ## Package facts - License: MIT (permissive) - Python support: supports_current - Install friction: low - Maintenance: active - Downloads: 125.7K/month (top 15,000 on PyPI) - Known vulnerabilities: none known ## Tags text case conversion, snake case kebab case camel case, string case formatter, convert between text cases, case conversion library, text formatting utilities, case transformation, string-formatting, case-conversion, text-processing [View on SkillFed](https://skillfed.io/packages/textcase) · [View on PyPI](https://pypi.org/project/textcase/)