DNS (Domain Name System) is a hierarchical naming system that translates domain names to IP addresses and vice versa. A DNS server is a computer that runs DNS services to provide name resolution. DNS works by querying multiple levels of DNS servers, starting from the root servers, then TLD (top-level domain) servers, then authoritative name servers, to ultimately resolve domain names to IP addresses.