Quick answer

YAML uses indentation to define structure.

YAML Invalid Indentation

YAML uses indentation to define structure. Each level must use the same character (spaces or tabs) and be aligned correctly. Wrong or inconsistent indentation causes parse errors.

Common causes

How to fix

Examples

Bad

name: app
  version: 1

Good

name: app
version: 1

FAQ

Can YAML use tabs for indentation?
Many parsers allow tabs, but the YAML spec recommends spaces. Mixing tabs and spaces is invalid.
How many spaces for YAML indent?
Common choices are 2 or 4 spaces per level; consistency matters more than the number.

Fix it now

Try in validator (prefill this example)

Related

All tools · Canonical