A GNU gettext utilities package for Go, providing complete PO/MO file support, pluralization, and thread-safe internationalization.
Gotext is a native Go implementation of GNU gettext utilities that provides robust internationalization (i18n) and localization (l10n) for Go applications. It enables developers to manage translations using standard PO and MO files without requiring external GNU gettext tools, solving the problem of building multilingual software in a Go-native, thread-safe way.
Go developers building applications that need to support multiple languages, particularly those who want a standards-compliant, dependency-free i18n solution integrated with Go's ecosystem.
Developers choose Gotext because it offers a pure Go, dependency-free implementation that fully supports GNU gettext standards (including PO files with pluralization, contexts, and variables) while being thread-safe and seamlessly integrating with Go's UTF-8 encoding, templates, and tooling.
Go (Golang) GNU gettext utilities package
Open-Awesome is built by the community, for the community. Submit a project, suggest an awesome list, or help improve the catalog on GitHub.
Implements all GNU gettext features like pluralization rules, message contexts, and PO/MO file handling, ensuring compatibility with existing translation workflows.
Designed for concurrent access across multiple goroutines, making it reliable for high-traffic Go applications without race conditions.
Eliminates external GNU gettext tool requirements, simplifying deployment and reducing system dependencies for pure Go environments.
Locale objects can be passed directly into Go templates, enabling straightforward i18n in web applications without extra boilerplate.
Enforces a specific directory structure (e.g., /lang/LC_MESSAGES/domain.po), which can be inflexible for projects with non-standard asset management.
Limited to PO and MO files, lacking native support for more modern translation formats commonly used in web and mobile apps.
Requires correct Plural-Forms headers in PO files, which can be complex and error-prone for languages with non-standard plural rules.