When do I use an A record?¶
A records are ideal for pointing your domain (or subdomain) at a server that has a static (does not change) IP address.
This is frequently the case when you want to point your domain (like “example.com”, or subdomain (like, “www.example.com”) to a server where your website is hosted, if your web host provides you with an IP address of the server where your content is stored (hosted).
Can I have an example?¶
Here is a model that you can follow:
www 10800 IN A 220.127.116.11
You will need to replace www with the name of the subdomain you want, and 18.104.22.168 in the above example with the IP address that your provider gives you.
As a reminder, * means “every subdomain”, so if you have an * A record, then there is no need for www unless you want to override the IP address you gave with your * entry.
If you want just the domain, then you need the @ record you see in the above example, or:
@ 10800 IN A 22.214.171.124
Usually both the * and @ are used, but one or the other (or both) will only work if the server hosting your website are configured for the particular address.