CoreDNS is a DNS server written in Go that has been the default cluster DNS for Kubernetes since 1.13, replacing kube-dns. Inside a Kubernetes cluster it resolves my-svc.my-namespace.svc.cluster.local to Service ClusterIPs, handles Pod A records, and forwards everything else upstream.
Its defining feature is the plugin chain. CoreDNS is built on the same Caddy core as the Caddy web server, and every feature — zone files, caching, Kubernetes service discovery, Prometheus metrics, rewrites, DNS-over-TLS — is a plugin compiled into the binary and composed via a Corefile. A query walks through the chain until a plugin answers it. The order in the Corefile matters, and swapping plugins in or out is a recompile (go build with a plugin list) rather than a dynamic load, which keeps the runtime small and predictable.
Beyond Kubernetes, CoreDNS is used as an authoritative and recursive DNS server in its own right, with backends for etcd, Consul, file-based zones, and external plugins for Redis, route53, and more. It’s a CNCF graduated project and, in practical terms, the de-facto DNS server of the cloud-native world — if you’re running Kubernetes, you’re running CoreDNS.