YAML (YAML Ain’t Markup Language) is a human-readable data serialization language commonly used for configuration files, automation, and data exchange. It uses indentation-based, whitespace-sensitive formatting to represent data structures like lists, dictionaries, and scalars, making it easy to read for developers and system administrators.
Originally, the acronym stood for “Yet Another Markup Language,” but it was renamed in 2002 to “YAML Ain’t Markup Language” to clarify its focus.
Key aspects of YAML:
- Purpose: Primarily used for configuration files in tools like Docker Compose, Kubernetes, and Ansible.
- Structure: Uses whitespace (spaces, not tabs) to indicate nesting. It is a strict superset of JSON, meaning it can handle JSON-style formatting in addition to its own.
- Readability: Designed to be much easier to read and write than XML or JSON.
- Components: Utilizes key-value pairs, ordered sequences (lists), and maps (dictionaries).
YAML files typically use a .yml or .yaml extension.
