Bridge CDN
On this page

Setting up DNS for a device or for a domain?

"DNS configuration" means two very different jobs, and it's worth knowing which one you're doing before you start.

Device DNS is the resolver your computer, phone or router asks. Changing it means typing an address like 1.1.1.1 or 8.8.8.8 into network settings. It affects only how you look up names. On Windows it's in the adapter's IPv4 properties. On macOS it's under Network › Details › DNS. On Linux, resolvectl status shows what's in use.

Domain DNS is the set of records the whole internet sees for your domain: where the website lives, where mail goes, which services you've verified. That's what these guides cover. If you want to know how to set up DNS so that example.com loads your site and receives your email, you're in the right place.

How to set up DNS for a domain in seven steps

Here's the order we recommend for any new zone. It's the same whether the domain is brand new or moving from another provider.

  1. List what the domain needs. Write down the website address, the mail provider, and any verification strings for services like search consoles or email platforms. For a moving domain, export the old zone.

  2. Create the zone in Bridge DNS. Import from Cloudflare with OAuth, scan the public DNS, or paste a zone file. For a new domain, add records by hand.

  3. Add or review the records. You need A or AAAA for the site, CNAME for aliases like www, MX and TXT for mail. Decide which A and AAAA records to proxy.

  4. Review the imported zone before delegation. Compare the records in Bridge with the records at your current provider, including mail and verification records.

  5. Change the nameservers at your registrar. Replace the old ones with ns1.bb-ns.com, ns1.bb-ns.net and ns1.bb-ns.org.

    Before step 5: if DNSSEC is active at the old provider, remove the DS record at the registrar first. A stale DS makes validating resolvers reject the domain.

  6. Turn on DNSSEC, if you want it. Enable it for the zone in Bridge, then complete DNSSEC delegation at your registrar if supported.

  7. Verify, then wait out the old delegation. Keep the old zone online and unchanged while resolvers may still have the previous delegation cached.

Done in this order, your domain keeps resolving through every step. Done in a different order, it usually still works, but one missing record can take out email for a day.

A starter zone for a website with email

Most small sites need only a few DNS records. Here's a realistic set for example.com, with a web server at 203.0.113.10 and mail hosted elsewhere:

@        A      203.0.113.10          ; proxied in Bridge
www      CNAME  example.com.
@        MX     10 mx1.example.net.
@        MX     20 mx2.example.net.
@        TXT    "v=spf1 include:_spf.example.net -all"
sel1._domainkey  CNAME  sel1.dkim.example.net.
_dmarc   TXT    "v=DMARC1; p=none; rua=mailto:dmarc@example.com"

A few notes on that set. The apex A record is proxied, so the server's address stays private. www is an alias, so you only maintain one address. Your mail provider gives you the MX, SPF and DKIM values; copy them exactly. DMARC starts at p=none so you can read reports before enforcing anything. If you publish a CAA record, it must allow the authority that issues your certificates, or new certificates will fail.

How to set up DNS for a subdomain

A subdomain like shop.example.com or docs.example.com lives in the same zone as the main domain, so you set it up with one more record. Which record depends on where it points:

  • Your own server: an A or AAAA record named shop. Proxy it if it serves a website.
  • A hosted platform (a store builder, a docs host, a help desk): a CNAME named docs pointing at the hostname the platform gives you. That's the normal case. Most platforms ask for a CNAME on a subdomain precisely because a CNAME can't sit at the apex.
  • A different DNS provider for that branch: NS records named shop, listing the other provider's nameservers. This delegates the whole subdomain away, and Bridge stops answering for anything under it.

Platforms often verify ownership with a TXT record on the same subdomain or on a _verify label. Add it before you click "verify" in their dashboard, then query it with dig to confirm it's live.

How to set up DNS records in the Bridge zone editor

To add a record:

  1. Open the zone editor and create a record.
  2. Pick the type: A, AAAA, CNAME, MX, TXT, NS, CAA, SRV, HTTPS, SVCB or TLSA.
  3. Enter the name. Use @ for the apex, or a label like www or mail.
  4. Enter the value exactly as your provider gave it. Hostnames in CNAME and MX values point at a name, never at an IP address.
  5. Leave TTL on Auto, or set your own.
  6. For A and AAAA records, decide on the proxy switch, then save.

The record is served by our nameservers within seconds. If you're editing a live zone, query it straight away with dig. A typo is cheaper to catch now than after resolvers have cached it.

How to plan a DNS change: a timeline

Changing a record is instant on our side. The planning is about everyone else's caches. Here's the timeline we use for any change that matters, whether it's a new server IP or a provider switch:

When What to do Why
Two days before Lower the TTL on the records you'll change, for example to 60–300 seconds Caches still hold the old, longer TTL. They need a full old-TTL period to pick up the short one.
Change day Make the change, then query the authoritative server and a public resolver You confirm the source is right before you wait on caches
Change + new TTL Check again from two or three networks Most resolvers have refreshed by now
Two days after Raise TTLs back if you lowered them, and clean up old records Short TTLs aren't harmful on Bridge, but long-lived records don't need them

On Bridge DNS the Auto TTL is already 60 seconds for A, AAAA and CNAME, so for those records step one is usually done. The table matters most when you're moving to Bridge from a provider that used one-hour or one-day TTLs.

Guides by task

Each guide covers one job: what to do, in what order, how to check it, and how to undo it.

TTL and propagation

TTL decides how long resolvers cache a record. Set it before a change, not after.

Moving DNS to Bridge

Import first, change nameservers last.

Proxy and origin

Email DNS

MX routes mail in. SPF and DKIM prove who may send. DMARC tells receivers what to do when those checks fail.

How to set up DNS for email in the right order

Email is where a careful order matters most, because a wrong record can silently send mail to spam rather than fail loudly. If you're working out how to set up DNS for a new mail provider, go in this sequence:

  1. MX first. Without MX records, nothing arrives. Use every MX host and priority your provider lists.
  2. SPF next. One TXT record starting v=spf1 at the domain. Merge senders into a single record. Two SPF records on one name make both invalid.
  3. DKIM third. Add the selector record exactly as given. Some providers use TXT, others CNAME.
  4. DMARC last, at p=none. Collect reports for a couple of weeks, then tighten to quarantine or reject once you've seen that legitimate mail passes.

Then send a test message to an external mailbox and read the authentication results in its headers.

How to check your DNS configuration

After you configure DNS, check the authoritative answer first, then what a public resolver returns:

dig @ns1.bb-ns.com example.com A +short
dig @1.1.1.1 example.com A +short
dig example.com NS +short

If the first line is right and the second is wrong, the resolver is still holding the old value; wait out the TTL. If the first line is wrong, fix the record in Bridge. If the NS answer doesn't list the Bridge nameservers, the registrar change hasn't taken effect yet, or it wasn't saved.

For mail, query MX, TXT and _dmarc the same way. Then send a test message and read the authentication results in its headers.

How to roll back a DNS change

Knowing how to set up DNS safely is mostly knowing how to undo it. Every DNS change can be reversed, but at different speeds:

  • A record change in Bridge: revert it in the editor. It's live in seconds, and resolvers drop the bad value after its TTL.
  • Nameserver change: put the old nameservers back at the registrar. This is slow, because resolvers follow the parent's 48-hour delegation TTL. Keep the old zone intact until you're sure.
  • DNSSEC: remove the DS record at the registrar first, then disable signing. Doing it the other way round breaks validation.

That's why we keep TTLs short by default and tell you to leave the old zone alone for two days.

Three rules that prevent most setup outages

  1. Lower TTLs before a change. Do it at least one full old-TTL period ahead.
  2. Copy every record before switching nameservers. Anything missing stops resolving as resolvers move over.
  3. Handle DNSSEC first. Remove the old DS before the move. Add the new one only after the Bridge delegation is live.

For definitions of the record types used above, see the documentation .

DNS setup questions

How do I set up DNS for my domain?

Create the domain's records at a DNS host, check them with dig, and change the nameservers at your registrar to point at that host. In Bridge DNS, import or add the records, then switch to ns1.bb-ns.com, ns1.bb-ns.net and ns1.bb-ns.org.

How long does DNS setup take?

Adding records in Bridge takes minutes, and each one is live on our nameservers within seconds. The nameserver change is slower. Resolvers switch once the cached delegation expires.

Which DNS records does a website need?

An A or AAAA record for the domain, and usually a CNAME or second A record for www. Add MX and TXT records if the domain sends or receives email. Add a CAA record if you want to restrict which authorities may issue certificates.

What is DNS configuration?

DNS configuration can mean the resolver settings on a device, or the records published for a domain. For a domain, it's the set of A, CNAME, MX, TXT and other records at your DNS host, plus the nameserver delegation at your registrar.

Can I configure DNS before moving the domain?

Yes, and you should. Build and check the whole zone in Bridge DNS first. Nothing changes for visitors until you update the nameservers at the registrar.

What TTL should I use when I set up DNS?

Keep Auto in Bridge DNS unless you have a reason not to: 60 seconds for A, AAAA and CNAME, 120 seconds for the rest. Raise a TTL only for records that never change. Lower TTLs at your old provider before a migration, at least one full old-TTL period ahead.

How do I set up DNS for a subdomain?

Add a record named after the subdomain in the same zone. Use an A or AAAA record for your own server, or a CNAME for a hosted platform's hostname. Use NS records only if a different DNS provider should answer for that whole subdomain.

Do I need to change nameservers to use Bridge DNS?

Yes. Bridge DNS answers for your domain only after the registrar delegates it to the three Bridge nameservers. Until then, your current provider keeps answering.