DNS record types

Understanding A records

An A (address) record maps a name to an IPv4 address. It's the record that sends visitors to your web server.

Updated · Published by HostFaddy · 3 min read

Look up the A record for any domain

Free, no sign-up — results in seconds.

What an A record looks like

example.co.za.       3600  IN  A  196.22.132.10
www.example.co.za.   3600  IN  A  196.22.132.10

Reading left to right: the name, the TTL in seconds, the class (always IN for internet), the type (A) and the value — a 32-bit IPv4 address.

What A records are used for

  • Pointing your root domain and www to your web server.
  • Giving mail servers (mail.example.co.za) an address that your MX record can refer to.
  • Pointing subdomains (shop, portal, staging) at different servers.

Multiple A records

A name can have several A records. Resolvers return all of them, and clients typically try them in turn — a simple form of load distribution known as round-robin DNS. It isn't health-aware, though: if one server is down, some visitors will still be sent to it.

Choosing a TTL

3,600 seconds (one hour) is a sensible default. Drop it to 300 seconds a day before a planned move so the change takes effect quickly, then raise it again afterwards. See how long DNS propagation takes.

Common A record mistakes

  • Updating the root but not www (or the other way round).
  • An A record and a CNAME on the same name. A name with a CNAME can't have any other records.
  • A leftover AAAA record pointing to an old server — IPv6 visitors will be sent there instead. Check with an AAAA lookup.
  • Pointing to a private address such as 192.168.x.x or 10.x.x.x, which isn't reachable from the internet.

Subdomains and wildcard A records

Every subdomain is its own name and needs its own record: shop.example.co.za doesn't inherit the root domain's A record. A wildcard record (*.example.co.za) answers for any subdomain that doesn't have a record of its own. Wildcards are handy for multi-tenant apps, but they also make typos resolve (wwww.example.co.za will load something), which can hide mistakes and help phishing look-alikes. Use them deliberately.

A records and email

Mail servers named in your MX records must have A (or AAAA) records. If your SPF record uses the a mechanism, the A record of your domain also decides which IP addresses are allowed to send mail — so changing web host can unexpectedly change your SPF result if mail and web share an IP.

How to look up an A record

Use our A record lookup to see what major public resolvers return, or from a terminal:

dig example.co.za A +short
nslookup -type=A example.co.za

Frequently asked questions

What's the difference between an A record and a CNAME?

An A record points a name directly to an IPv4 address. A CNAME points a name to another name, which is then resolved to an address.

Can my root domain use a CNAME instead of an A record?

Not in standard DNS. The root must use A/AAAA records. Some providers offer ALIAS, ANAME or CNAME flattening to emulate it.

How do I find my server's IP address?

It's shown in your hosting control panel or welcome email. Your host can also confirm it.