A toolkit for creating structured configuration languages that are both human- and machine-friendly, primarily for devops tools and servers.
HCL is a toolkit for creating structured configuration languages that are both human-readable and machine-friendly. It provides a syntax and API specifically designed for building configuration formats, primarily targeting devops tools and servers. It combines a native, human-friendly syntax with a JSON variant, allowing for dynamic expressions and structured validation.
Developers and devops engineers building or using configuration-driven tools, especially those in the HashiCorp ecosystem (like Terraform) or anyone needing a structured, readable configuration format.
Developers choose HCL because it offers a balanced approach between simple serialization formats and full programming languages, providing human readability, machine parseability, and support for dynamic expressions without the complexity of a full scripting language.
HCL is the HashiCorp configuration language.
Open-Awesome is built by the community, for the community. Submit a project, suggest an awesome list, or help improve the catalog on GitHub.
The native syntax is inspired by libucl and nginx, designed for easy reading and writing, as shown in the clean, block-based config.hcl example.
Supports a JSON-based variant that shares the same data model, allowing seamless mixing of human-authored native syntax and machine-generated JSON configs.
Includes inline expressions for computation, variables, and functions, enabling declarative logic in configurations without full scripting, as demonstrated with arithmetic and string interpolation.
Applications can define expected attribute names and block types, leading to better error messages and validation, which is a core part of HCL's philosophy for robust configs.
HCL 2.0 has a completely new Go API with no direct migration path from HCL 1.0, requiring significant refactoring for upgrades, as noted in the version selection warning.
Primarily a Go toolkit, so it's less suitable for projects in other languages without community ports, limiting its use outside the Go ecosystem.
While it supports expressions, it's not a full programming language; complex logic or advanced control flow might still require external scripting or application logic.