CLOUD
Guides

DNS Migration: How to Switch Without Issues

CLOUD|January 4, 2026|5 min read|384 views
DNS Migration: How to Switch Without Issues

TTL, nameservers, propagation — DNS migration needs planning. We explain: how to minimize transition time and avoid common mistakes.

Why DNS Migration Matters

DNS is the system that translates domain names into IP addresses. When you migrate your server, you need to tell DNS that your domain now points to a new IP address. A single mistake in this phase means your site disappears from the internet — even if the new server is perfectly ready and running.

This guide walks through every step of DNS migration, from preparation to final verification.

Understanding Core DNS Records

Record TypeFunctionExample
AMaps domain to IPv4 addressexample.com → 1.2.3.4
AAAAMaps domain to IPv6 addressexample.com → 2001:db8::1
CNAMEAlias for another domainwww → example.com
MXMail servermail.example.com (priority 10)
TXTVarious text records (SPF, DKIM, verification)v=spf1 include:... -all
NSAuthoritative name serversns1.provider.com

Step 1: Document Current Records (One Week Before)

Before making any changes, document every existing DNS record. This gives you a reference to fall back on if anything goes wrong:

  1. Log into your current DNS provider (Cloudflare, Route53, or domain registrar)
  2. Screenshot all records or export them as a file
  3. Run dig example.com ANY from the terminal to document actual resolved values
  4. Save a copy somewhere safe outside both old and new servers

Commonly Overlooked Records

  • SPF and DKIM records: without them your emails go to spam
  • DMARC records: policy for handling spoofed emails
  • SRV records: if you use services like SIP or XMPP
  • CAA records: specify which certificate authorities can issue SSL certificates

Step 2: Lower TTL (48 Hours Before)

TTL (Time To Live) determines how long a DNS record is cached. If your current TTL is 86400 seconds (24 hours), it means that after you change the record, some users will still reach the old server for an entire day.

The solution: lower TTL 48 hours before the switchover:

  • Set TTL to 300 seconds (5 minutes) for all A, AAAA, and CNAME records
  • Wait for the old TTL duration (e.g., 24 hours) so the change propagates
  • Verify the new TTL is active: dig example.com +noall +answer

Step 3: Fully Prepare the New Server

Do not change DNS until the new server is 100% ready:

  1. Application is deployed and tested
  2. Database is up to date and synchronized
  3. SSL certificate installed (you can use DNS validation to issue it before the switch)
  4. Firewall allows HTTP/HTTPS traffic
  5. Tested via local hosts file modification

Step 4: Execute the Switch

Scenario 1: Changing A Record Only (Same DNS Provider)

The simplest scenario. Update the IP address in the A record to the new server address. With a low TTL, users transition within 5 minutes.

Scenario 2: Changing Name Servers (NS Records)

If you are moving to an entirely new DNS provider (e.g., from your registrar to Cloudflare):

  1. Create all records in the new DNS provider first
  2. Verify every record matches the old configuration
  3. Change name servers (NS) at your domain registrar
  4. Allow 24-48 hours for full propagation

Scenario 3: Migration with Cloudflare Proxy

If you use Cloudflare in proxy mode, the switch is easier because users connect to Cloudflare, not your server directly. Change the origin address in Cloudflare and it takes effect immediately.

Step 5: Monitor and Verify

After executing the switch, monitor closely:

  • Use whatsmydns.net to track global DNS propagation
  • Verify the site works from different devices and locations
  • Monitor new server logs: is it receiving traffic?
  • Monitor old server logs: is traffic decreasing?
  • Test email: send and receive from different addresses

Step 6: After the Switch

  1. Keep the old server running for at least 48-72 hours
  2. Raise TTL back to a higher value (3600 or 86400) after confirming stability
  3. Update any services that depend on the old IP address
  4. Update SPF records if the mail server IP changed
  5. Document everything that was changed for future reference

Mistakes to Avoid

  • Changing DNS when the new server is not ready
  • Forgetting to lower TTL in advance: delays the switch by hours
  • Forgetting MX records: email stops working
  • Forgetting to update SPF/DKIM: emails go to spam
  • Deleting the old server immediately: some users have not transitioned yet

Useful DNS Migration Tools

ToolUsageCost
whatsmydns.netMonitor DNS propagation from 25+ locations worldwideFree
dig (terminal)Direct DNS query with full detailsBuilt into Linux
nslookup (terminal)Simple and quick DNS lookupBuilt into all OS
MXToolboxCheck MX, SPF, DKIM, and DMARC recordsFree
DNSChecker.orgDNS propagation check with visual mapFree

Tips for .sa Domain Migrations

Saudi domains (.sa, .com.sa, .net.sa) are managed through the Communications, Space and Technology Commission (CST) or through accredited registrars. When changing name servers for a Saudi domain:

  • The change may take 24-48 hours to fully propagate — sometimes longer than international domains
  • Verify that the new name servers respond correctly before making the change at the registrar
  • Keep a copy of your registrar account credentials — you need them to update NS Records
  • If using Cloudflare, add your domain there first and verify all records are correct before switching

DNS Migration to CLOUD Servers

When moving to CLOUD (cloud.net.sa) servers, you get a dedicated Saudi IP address from the Riyadh or Jeddah data center. This means very low latency latency for users inside Saudi Arabia. The CLOUD team assists your developer with planning and executing DNS migration correctly through free technical guidance sessions.

DNS migration is not complicated, but it does not tolerate mistakes. Document everything, lower TTL in advance, and confirm the new server is 100% ready before making any changes. Follow the steps and the switch happens smoothly within minutes.

--- ### Get Started Want to try it yourself? Choose the right hosting plan or build your custom server with the specs you need.
Share