YAML Indentation and Structure/Mixed indentation example

Illustrate a broken file caused by inconsistent nesting.

Section: Indentation rules

Mixed indentation example

yaml
yaml
app:
  name: Cheatsheet.today
   seo:
    enabled: true
Explanation

Even one extra space can change meaning or break parsing altogether.

Learn the surrounding workflow

Compare similar commands or jump into common fixes when this command is part of a bigger troubleshooting path.

Related commands

Same sheet · prioritizing Indentation rules
Two-space indentation
Use consistent spaces for nested levels.
OpenIn sheetyamlsame section
Sequence nested under a key
Indent list items under their parent key.
OpenIn sheetyamlsame section
Mappings inside a sequence
Represent a list of objects cleanly.
OpenIn sheetyamlsame section
Run yamllint with a custom config
Use a project-specific lint profile.
OpenIn sheetbash1 tag match
Reveal hidden whitespace
Print tabs and line endings to spot indentation issues.
OpenIn sheetbash1 tag match
Find tabs in YAML files
Locate tab characters that may break parsing.
OpenIn sheetbash1 tag match