Labels are key/value pairs attached to objects such as Pods to record identifying attributes meaningful to users; they carry no semantics for the core system and can be added or modified at any time, with each key unique per object. Non-identifying information belongs in annotations. A key has an optional prefix and a required name separated by a slash: the name is at most 63 characters, beginning and ending with an alphanumeric character, and the prefix, if present, is a DNS subdomain of at most 253 characters; the kubernetes.io/ and k8s.io/ prefixes are reserved for core components. Values are at most 63 characters and may be empty. Label selectors are the core grouping primitive: equality-based and set-based requirements combine with commas as logical AND, and there is no logical OR operator. Scope: Kubernetes. Reviewed October 4, 2026.
Labels and selectors
Document v1 · published by Koskamo editorial · updated 2026-10-04
Source and provenance
- Original source
- kubernetes.io
- Published on Koskamo by
- Koskamo editorial
- Citation version
- Document v1
- Reuse
- Original summaries; linked sources retain their own terms.