Import DNS records from a zone file
When you move a domain's DNS to Barbrick, you don't need to retype every record. Paste the zone file from your old DNS provider, check what will change, and import it in one step. This is for anyone moving a domain to Barbrick's nameservers.
Before you start
- Download the zone file from your old DNS provider. Most have an Export or Download zone file option in their DNS settings. The file is plain text and often ends in
.txt,.zoneor.db. - Leave the nameservers where they are for now. Import first, then switch to Barbrick's nameservers, so your site and email keep working through the move.
A zone file looks like this:
$ORIGIN example.ca.
$TTL 3600
@ IN A 198.51.100.24
www IN CNAME example.ca.
@ IN MX 10 mx1.mailhost.example.
@ IN TXT "v=spf1 include:_spf.mailhost.example ~all"
shop IN CNAME shops.example.net.
Import the records
- Sign in at
https://barbrick.ca/account. - Go to Account → Hosting → your site → Import a zone.
- If you have more than one domain, choose it and click Show.
- Paste the zone file into Zone file, or click Open a file and choose the file you downloaded.
- Click Preview changes. Nothing is saved yet.
- Check the preview and tick the rows you want.
- Click Import records. The button shows how many records it will add.
- Confirm with Import.
Read the preview
Each row is a name and record type, with the values from your file.
| Change | Means | Ticked to start |
|---|---|---|
| New | Nothing like it here yet. The records are added | Yes |
| New TTL | The same values with a different TTL. The TTL is updated | Yes |
| Differs | Different values are here now. Ticking replaces them with the file's values | No |
Rows marked Differs start unticked because they would replace what's working now. The most common one is the domain's own A record. Here it points at your Barbrick site; in the file it points at your old host. Leave it unticked to keep your site on Barbrick.
A few more things the preview handles for you:
- TXT records from the file are added next to the ones already here. A second SPF record shows as Differs, because a name can have only one.
- Records already here are counted at the top and not listed.
- Records not in the file stay exactly as they are. An import never deletes a record unless you tick a Differs row that replaces it.
What isn't imported
Lines that can't be imported are listed under the preview with the reason. These are skipped:
| Skipped | Why |
|---|---|
| SOA (start of authority) | Managed for you |
| NS records | Your nameservers are managed for you. To hand a subdomain to another DNS provider, ask us |
| Names outside your domain | They belong to another zone |
| Record types other than A, AAAA, CNAME, MX, TXT, SRV and CAA | Add them from DNS if you need them, or ask us |
$INCLUDE and $GENERATE lines |
Paste the records themselves instead |
Records for control panel addresses are also kept as they are, because we keep them working for you.
A file can be up to 256 KB and 1,000 records. Split a bigger file into parts and import each one.
Undo an import
An import is saved in DNS history as one change. To undo it, open DNS history, open the import, and click Undo change. See See DNS changes and undo one.
Switch your nameservers
Once the records look right, set your domain's nameservers to gordon.barbrick.ca, hugh.barbrick.ca and douglas.barbrick.ca. See Use Barbrick's nameservers. The switch usually shows within a few hours; allow up to 24.
If something goes wrong
- "Your DNS records changed since the preview": someone saved a change while you were reviewing. The preview refreshes; check it and import again.
- A line you expected is skipped: read the reason under the preview. Most often the name is outside your domain because the file's
$ORIGINis missing or different. Add$ORIGIN example.ca.as the first line, with your own domain and the final dot. - "Nothing in this file can be imported": make sure you pasted the zone file itself, not a page of DNS settings.
Still stuck? Ask us and we'll walk you through it.
