What's the meaning of '@' in a DNS zone file?

Better Stack Team
Updated on November 23, 2023

In DNS (Domain Name System) zone files, the '@' symbol represents the origin or root of the domain itself. It is used as a placeholder to denote the domain name itself within the zone file.

The '@' symbol is commonly used to refer to the zone's domain name within the file. For example, in a typical zone file for a domain such as "example.com", the '@' symbol represents "example.com" itself. It is a shorthand way of referring to the domain name without explicitly typing it out.

For instance, in a DNS zone file, an 'A' record for the domain's root might look like this:

 
@    IN    A    192.0.2.1

Here, '@' refers to the domain name "example.com". It indicates that the IPv4 address 192.0.2.1 is associated with the root of the "example.com" domain.

Using '@' in the zone file makes it more concise and clear, especially when defining records for the domain itself, rather than repeatedly typing out the full domain name in each record within the zone file.