Kubernetes YAML validator

Paste one or more Kubernetes manifests to check them before you run kubectl apply. The validator finds YAML errors, missing fields, outdated API versions, labels that do not match and common best-practice problems.

How to use the kubernetes YAML validator

  1. Paste your manifest or click Open File. Several resources separated by --- are fine.
  2. Read the findings for each resource. Errors will stop the resource from working, and warnings are worth a look.
  3. Fix the YAML and paste it again until the errors are gone.

What is checked

CheckExample of what it catches
YAML syntaxTabs, bad indentation and duplicate keys, with the line number
Required fieldsA missing apiVersion, kind, metadata.name or spec
API versionsextensions/v1beta1 for a Deployment or Ingress, which current clusters reject
Names and labelsCapital letters or underscores in a resource name
SelectorsA Deployment whose selector.matchLabels does not match its pod template labels
Links between resourcesA Service whose selector matches no workload in the same file
ContainersNo image, duplicate container names, an untagged or :latest image
Ports and valuesA port outside 1 to 65535, a memory limit written as 512 instead of 512Mi
Secretsdata values that are not valid Base64
CronJobsA schedule that is not five fields
Best practiceNo resource requests or limits, no health probes, privileged containers, running as root

The mistake that wastes the most time

A Deployment creates pods from its template, then finds them again by label. If spec.selector.matchLabels says app: web and the template's labels say app: website, the API server rejects the Deployment. A Service has the same trap with a quieter failure: if its selector matches no pods, it is created without complaint and simply sends traffic nowhere.

What this tool cannot check

It does not connect to your cluster, so it cannot tell whether a namespace, ConfigMap, image or storage class really exists, and it does not know your custom resource definitions. For a final check against the real API server, run:

kubectl apply --dry-run=server -f manifest.yaml
kubectl diff -f manifest.yaml

For plain YAML checks and conversion to JSON, use the YAML validator. Check a CronJob schedule with the cron expression generator, and encode Secret values with the Base64 encoder.

Private by design

This tool runs entirely in your web browser. Nothing you type or paste is sent to a server, logged or stored, so it is safe to use with internal addresses, configuration files and other work data. There is no sign-up and it keeps working offline once the page has loaded.

Frequently asked questions

How do I validate a Kubernetes YAML file?

Paste it into the box. Syntax errors, missing fields and mismatched labels are listed for each resource.

Does this replace kubectl apply --dry-run?

No. It catches the most common problems without a cluster, but only the API server can check against your real cluster and custom resources.

Why should I not use the latest image tag?

It makes deployments unpredictable. Two pods can run different versions, and you cannot roll back to a known image.

Is my manifest uploaded?

No. It is checked in your browser. Do keep real Secret values out of anything you paste into websites as a habit.

Can I check several resources at once?

Yes. Separate them with a line containing three dashes. Links between them, such as a Service and its Deployment, are checked too.