1666889← Home

Docker Compose Validator

Paste your docker-compose.yml and get every issue listed with its line number, what is wrong, and how to fix it. Everything runs locally in your browser — nothing is uploaded.

Note: browser validation is not docker compose config.This tool only does static checks (YAML syntax, configuration structure, and common rules). It does not pull images, read .env files, or verify that host networks, volumes, and ports are actually available, so it cannot replace the official docker compose config check. Always run the official command before deploying.

Three layers of checks

  1. YAML syntax: parsed with js-yaml; syntax errors are reported with line numbers.
  2. Structure: validated with AJV against a Compose structure schema (services / image / build / ports / volumes and more); missing fields and wrong types are flagged.
  3. Hand-written rules: untagged images, the latest tag, invalid image names, the deprecated version field, privileged ports, host port conflicts, container-only port mappings, relative-path volumes, undeclared named volumes, depends_on pointing at missing services, container_name conflicts, missing restart, and suspected plaintext secrets.

Common pitfalls

  • An image with no tag means latest, so deploys are not reproducible — pin a specific version or digest.
  • The version field is deprecated and ignored by Compose V2 — delete it.
  • Two services cannot bind the same host port; change one of them.
  • Host ports below 1024 need privileges; use ports above 1024 for local development.
  • Named volumes must be declared under top-level volumes:, or Compose will report them as undeclared.

Frequently asked questions

Is my docker-compose.yml uploaded anywhere?
No. Everything runs locally in your browser. Your file is parsed and validated on your own device, and nothing is sent to any server.
What does the validator check?
Three layers: YAML syntax, structure validation against a Compose schema subset, and hand-written rules covering image tags and image name format, the deprecated version field, host port conflicts and privileged ports, volumes, depends_on targets, container_name conflicts, missing restart policies, and plaintext secrets.
Does this replace docker compose config?
No. Browser validation is static checking only: it does not pull images, read .env files, or verify that host networks, volumes, and ports are actually available. Always run docker compose config before deploying.
Should I keep the version field in my compose file?
No. The version field is deprecated and ignored by Compose V2. Delete the version: line; removing it changes nothing.

More tools are coming. Back to thetool list.