If you don't know how to edit your zone file, see the step-by-step tutorial.
You have two options for editing your zone file: normal and expert.
In normal mode (recommended for beginners), your zone file will be shown with each resource record on its own line, like this:
Click the pencil icon to edit the corresponding line, or click “Add” to add a new record.
You will be presented with a form that looks like this:
Each field corresponds to one of these example columns:
Type | TTL | Name | Value | Effect |
---|---|---|---|---|
Record type | Lifespan | Subdomain | IP Address (IPv4) | |
A | 3 hours | www | 123.123.123.123 | www.mydomain.tld will point at the server found at 123.123.123.123 . |
A | 3 hours | @ | 456.456.456.456 | mydomain.tld will point at the server found at 456.456.456.456 . |
A | 3 hours | * | 789.789.789.789 | All subdomains not otherwise specified will point at the server found at 789.789.789.789 . |
A | 3 hours | photos | 333.333.333.333 | photos.mydomain.tld will point at the server found at 333.333.333.333 |
For example, if all of the records above existed in the zone file of domain mydomain.tld
:
mydomain.tld
will point at 456.456.456.456
www.mydomain.tld
will point at 123.123.123.123
www2.mydomain.tld
will point at 789.789.789.789
photos.mydomain.tld
will point at 333.333.333.333
blog.mydomain.tld
will point at 789.789.789.789
Note that the configuration above would cause mydomain.tld
and www.mydomain.tld
to point to different servers (probably not your desired effect).
When you're done, be sure to click Submit. You will see this message:
Then, you must click “Activate this version”:
You'll receive a confirmation message that the zone file's version has been changed.
Now, you just have to wait about three hours for your changes to propagate.
In expert mode, your zone file will look something like this:
You will now need to add your desired A line.
Here is a model that you can follow:
www 10800 IN A 123.123.123.123
Simply replace www
with the name of the subdomain you want, and 123.123.123.123
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 123.123.123.123
Usually both the *
and @
are used.
When you are done, click on the “Submit” button on the bottom of the page to continue.
All that remains now is to wait for the changes to take affect, so for this please wait at least 3 hours.
A records are ideal for pointing your domain (or subdomain) at a server that has a static IP.
A records don't work well in scenarios where your server IP changes a lot. You might want to use a CNAME record instead.