.YAML

YAML File

YAML Ain't Markup Language file
Ask a question
QUICK ANSWER

A .yaml (or .yml) file is plain-text structured data or configuration written in YAML, used for CI/CD pipelines, Docker Compose, Kubernetes manifests, and app config. Open it in any code editor -- VS Code with the YAML extension is the safest choice because it flags indentation errors. YAML requires spaces for indentation; a stray tab causes a parse error.

Developer: Clark Evans, Ingy döt Net, Oren Ben-Kiki (YAML spec) Category: Developer Files Open standard MIME: application/yaml
OPENS ON Windows macOS Linux Web
Related: .DO · .MD · .HEX · .XSD

On this page

19k+ extensions indexed
Last reviewed Aug 3, 2026

Not sure what your file is?

Drop any file into our identifier - we read just the first bytes to name the format.

Identify a file

What is the YAML file format?

.yaml is a text file format used for exchanging data between various applications. YAML - short for *YAML Ain't Markup Language* - is a standard for organizing information in a human-readable, platform-independent format using indentation-based key: value pairs encoded in UTF-8. Parsing .yaml files requires a YAML library to be installed; popular libraries include PyYAML (Python), js-yaml (JavaScript), and SnakeYAML (Java). .yaml files are sometimes saved with the .yml extension, which is functionally identical. Beyond data interchange, .yaml files are typically used for serializing data and for writing configuration files in tools such as Docker Compose, Kubernetes, and GitHub Actions.

Serialization

Serialization is a term used in computer science. Serialization is a process of translating data or objects into a format that can be stored, transmitted, and reconstructed later. For example, two institutions exchanging some data in a standardized format using different applications must serialize that data before sending it. Serialized data can also be stored in a file - .yaml, .xml, .json, .toml, etc. - and then sent to the recipients.

A .yaml document may optionally begin with the --- document-start marker and end with ...; this also allows multiple documents inside a single file. Since YAML 1.2 (2009, revised 2021), every valid JSON file is also valid YAML.

Security & safety

RISK: MEDIUM

A YAML file is plain text and doesn't execute on its own, so reading one is safe. Two real risks: (1) config YAML (CI pipelines, Compose, K8s, Ansible) frequently contains secrets - tokens, passwords, keys - so don't paste it into untrusted online validators or commit it publicly. (2) Programmatic danger: loading untrusted YAML with an unsafe parser (e.g. PyYAML's yaml.load instead of yaml.safe_load) can execute arbitrary objects/code - always use the safe loader for files you don't trust. Editing risk: a tab or a misaligned space silently changes meaning, so validate after editing.

Format details

in a nutshell
FULL NAMEYAML Ain't Markup Language file
DEVELOPERClark Evans, Ingy döt Net, Oren Ben-Kiki (YAML spec)since 2001 (YAML 1.0); YAML 1.1 (2005); current YAML 1.2 (2009, revised 2021)
MIME TYPEapplication/yaml
TYPEHuman-readable data-serialization text (indentation-based, UTF-8)
STANDARDOpen · royalty-free

Programs that open YAML files

Windows4 apps
Sublime Text Freemium Open the .yaml for fast editing with YAML highlighting; configure 'translate tabs to spaces' so indentation stays valid.
Windows Notepad Built-in Opens YAML as text for a quick look - but it doesn't show whitespace/tabs, so it's risky for editing indentation-sensitive YAML.
Notepad Open-source Open with YAML syntax highlighting; turn on View > Show Symbol > Show White Space to keep indentation correct.
Visual Studio Code Free Open the file; the built-in/Red Hat YAML extension gives highlighting, indentation guides, schema validation and error squiggles. Best choice for YAML.
macOS3 apps
TextEdit Built-in Format > Make Plain Text first, and disable smart quotes - but it won't show whitespace, so prefer a code editor for editing.
Visual Studio Code Free Open and edit with the YAML extension (highlighting, schema validation). Recommended over TextEdit.
Sublime Text / BBEdit Freemium Open the .yaml in a code editor for proper YAML highlighting and space-based indentation.
Linux3 apps
Visual Studio Code Free Open and edit with the YAML extension; available as .deb/.rpm/flatpak.
GNOME Text Editor / gedit Open-source Open with YAML highlighting; set it to insert spaces (not tabs) before editing.
vim / nano Open-source Edit in the terminal; in Vim use ':set expandtab' so indentation uses spaces. Standard for server config files.
Web1 app
YAML Lint / online YAML validators Free Paste the file to validate syntax and pretty-print it in the browser. Don't paste secrets - config YAML often holds credentials.

Technical details

deep spec
File extension.yaml (also .yml)
MIME typeapplication/yaml
EncodingUTF-8 plain text; no binary header or magic bytes
StructureIndentation-based key: value pairs; indentation uses spaces only - tabs are forbidden by the spec
Document markers--- marks document start, ... marks document end; multiple documents can coexist in one file
Native data typesStrings, integers, floats, booleans, null, sequences (lists), mappings (dictionaries), timestamps
Spec versionYAML 1.2 (2009, revised 2021); supersedes YAML 1.1 (2005) and YAML 1.0 (2001)
JSON compatibilitySince YAML 1.2, every valid JSON document is also valid YAML - JSON is a strict subset
CommentsSingle-line comments introduced by # ; may appear on their own line or inline after a value
Multiline stringsLiteral block scalar (|) preserves newlines; folded scalar (>) converts newlines to spaces
Anchors and aliases& defines a named anchor and * references (aliases) it, enabling value reuse without duplication
DevelopersClark Evans, Ingy döt Net, Oren Ben-Kiki
Common use casesConfiguration files (Kubernetes, Docker Compose, GitHub Actions, Ansible), data serialization, OpenAPI definitions
QuotingUnquoted, single-quoted ('...'), and double-quoted ("...") strings all supported; double-quoted allows escape sequences
Released2001 (YAML 1.0); YAML 1.1 (2005); current YAML 1.2 (2009, revised 2021)
Open standardYes · royalty-free
Specificationyaml.org

YAML conversions

Community Q&A

asked by users
Ask a quick question
Get help from people who work with YAML files. Be specific - include your system and software version.
No account needed · answers usually within a day
I
Ilario16 d agoUNANSWERED
A cosa serve
Waiting for an answer

Frequently asked questions

What's the difference between .yaml and .yml?
None - they're the same YAML format with two extensions. .yml is the older 3-letter form. Use whichever the tool expects; you can simply rename the file.
How do I open a .yaml file?
With any code/text editor. VS Code (with the YAML extension) is best because it highlights structure and flags indentation errors; Notepad++ and Sublime work too. It's plain text, so Notepad opens it - but it won't show whitespace, which YAML cares about.
Why is my YAML giving an indentation/parse error?
YAML uses spaces for structure and forbids tabs, so a stray tab or a misaligned line breaks it. Open it in a YAML-aware editor (show whitespace, convert tabs to spaces) or paste it into an online YAML validator to find the exact line.
How do I convert YAML to JSON?
Use 'yq -o=json file.yaml', a VS Code command, or an online converter. It's essentially lossless since JSON is a subset of YAML - only comments are dropped.
Can I use tabs in YAML?
No. YAML only allows spaces for indentation; tabs cause a parse error. Set your editor to insert spaces (e.g. ':set expandtab' in Vim, or 'translate tabs to spaces' in Sublime).
Is YAML only for Python?
No - that's a common misconception. YAML is language-independent and is used everywhere: Docker Compose, Kubernetes, GitHub Actions, Ansible, Go/Java/JS apps and more. Python just happens to have a popular YAML library (PyYAML).

References

1YAML 1.2.2 Specification (yaml.org)yaml.org
2yaml.org - official site & resourcesyaml.org

Keep exploring

across the database

Top extensions this week

1.AQQAQQ Instant Messenger File
2.CRDOWNLOADChrome Partial Download File
3.PARTPartial Download File
4.DATProgram Data File (generic)
5.EXEWindows Executable (Portable Executable)
6.BINCD/DVD Disc Image (BIN/CUE)
7.RPMSGRestricted Permission Message
8.NOMEDIAAndroid No-Media Marker File
9.TXTPlain Text File
10.MDMarkdown Document

Related extensions

.DOStata Do-File
.MDMarkdown Document
.HEXIntel HEX File
.XSDXML Schema Definition
.MAPSource Map (JavaScript / CSS)
.CONFIGConfiguration File

Free file tools

An in-browser file identifier and image converter - everything runs on your device.

Open the toolbox

Browse file extensions A-Z