The workshop · Edition No. 50 · 14 Oct 2026

google/yamlfmt

A command-line formatter and linter for YAML files, usable as a tool, a library or a container image.

← The workshopRead the whole edition →
03

google/yamlfmt

💎 hidden gem
yamlfmt: tidying settings files. Rewrites configuration files in one layout.

1,837 stars · Apache-2.0, read from /blob/main/LICENSE on 2026-10-12, standard text with the copyright holder placeholder unfilled; formatter.go carries 'Copyright 2024 Google LLC' · v0.21.0 (2026-01-05), settled exactly by ungh's releases endpoint at 2026-01-05T18:42:15Z · Track this in Scout

A command-line formatter and linter for YAML files, usable as a tool, a library or a container image.

▶Repo detailsthe review · specs · pros & cons · install

What it does

You give it file names, or a folder, and it rewrites each file in a consistent layout. Pointing it at a folder makes it walk through everything inside and pick up files ending in .yaml and .yml. One flag switches on a wider pattern syntax, so you can describe exactly which files to include. A check mode reports what it would change and alters nothing, which is what you run before accepting a change rather than while writing one. Settings go in a .yamlfmt file, and the formatting itself is pluggable, so a different style can be added. It also works as a library inside another program, and there is a container image, so it can run without being installed. Release files carry checksums and are signed, from version 0.14.0 onward. The newest release is v0.21.0, from 5 January 2026, and code landed on 13 October 2026. What it explicitly does not have is official backing. The README states the project is not yet officially supported by Google, and that it is maintained by one person working on it mostly in spare time.

Why it matters

Who it suits. Anyone with a pile of YAML files that several people edit: container settings, build pipelines, deployment descriptions. The check mode is the part that pays for itself, because it ends the argument about indentation by moving it to a program. Skip it if YAML barely appears in your work, or if a general formatter already covers it, because this does one format and nothing else.

Verdict. A good small tool, and the thing to understand is the ownership rather than the code. An account name of google on GitHub tells you who owns the account, not who is on call. This project says in its own README that Google does not officially support it and that one person maintains it in spare time, and nine months between releases is consistent with that. None of this makes it a bad choice, because a formatter that goes quiet still formats. It does mean you should not pick it over an alternative on the strength of the name. prettier/prettier at 52,300 stars formats YAML among many other languages and is the better choice if a project already runs it for JavaScript or Markdown. mikefarah/yq at 15,900 stars is a different job that often gets confused with this one: it reads and edits values inside YAML rather than tidying the layout.

Stars1,837
LicenceApache-2.0, read from /blob/main/LICENSE on 2026-10-12, standard text with the copyright holder placeholder unfilled; formatter.go carries 'Copyright 2024 Google LLC'
Latestv0.21.0 (2026-01-05), settled exactly by ungh's releases endpoint at 2026-01-05T18:42:15Z
Good
  • One small program with nothing to install first, plus a container image for running it without installing.
  • A check mode that reports and changes nothing, which is what a build pipeline needs.
  • Release files are checksummed and signed, which is unusual for a tool this size.
Watch for
  • The README states it is not officially supported by Google and has one maintainer working in spare time.
  • Nine months passed between the newest release and the one before it.
  • It handles YAML only, so a project with several file formats needs a second formatter anyway.
Similar repositories
  • prettier/prettier

    Formats YAML along with JavaScript, CSS and Markdown, at 52,300 stars, under an MIT licence; the better choice when a project needs one formatter for everything.

    Track this in Scout
  • mikefarah/yq

    Reads and edits the values inside YAML, JSON, XML, CSV and TOML files rather than formatting them, at 15,900 stars, under an MIT licence.

    Track this in Scout
Install
go install github.com/google/yamlfmt/cmd/yamlfmt@latest
Screenshots
google/yamlfmt: GitHub preview card

Get the next edition in your inbox

A dozen repositories, opened and checked. The licence read, the last release dated, and the ones that did not make it named with the reason. It is the half most lists leave out.

No tracking pixels. One click to leave. The archive stays free either way.

We use your address to send the edition and nothing else. Confirm by email, leave in one click. How we handle it.