Web hosting · Practical guide

Change DNS records with a simple rollback plan

Save the existing records, change the right DNS service and verify the result before retiring the old setup.

Archive placement: December 2023

Network patch cables connected to a server rack

A DNS change is small enough to look harmless but can affect the website, mail and verification records at once. Identify the DNS service that actually answers for the domain, save the current values, and change only the records needed for the move. Then check both the authoritative answer and what visitors receive.

1. Find the DNS service that controls the domain

Editing a cPanel zone only affects the public domain when that zone is served by its authoritative DNS provider. Registration, website hosting and DNS can be with different companies.

  1. Check the nameservers shown in your domain registration account. If you are unsure who operates them, ask the registrar or hosting team.
  2. Open cPanel → Zone Editor and choose Manage for the domain to inspect the available records.
  3. If the nameservers belong to another DNS provider, make the public record change there instead. Use cPanel as a reference only until you have confirmed which zone is authoritative.

Do not change nameservers just because you want to change one website address. A nameserver move affects the entire zone, including mail and verification records, and requires a separate migration plan.

2. Make a record-by-record change sheet

In the authoritative DNS provider’s control panel, export the zone or save the relevant records. Record each name, type, value and TTL. Include the root domain, www, mail-related hostnames, MX, TXT and any service records. Screenshots are useful, but a written list is easier to compare and restore.

  • A: an IPv4 address for a hostname.
  • AAAA: an IPv6 address; update it too if the host is moving and IPv6 is used.
  • CNAME: an alias to a hostname, not a URL with https:// or a page path.
  • MX: the receiving mail destination, with a priority. TXT records may authorise senders or verify services.

Check dependencies. If the MX points to example.com itself, changing that name’s A record also changes where mail is delivered. Likewise, mail.example.com may be an alias to the website. Separate those dependencies before assuming a website-only change cannot affect email.

3. Save the records you must preserve

Record website A, AAAA and CNAME entries, plus MX and mail-related TXT records. Include verification records used by external services. Do not replace a complete DNS zone just to move one website address.

If you control the TTL, reduce it well before the planned change. Existing cached answers keep their previous TTL, so lowering it at the last minute does not instantly clear those caches. Note the old address and a clear condition for rolling back.

4. Prepare TTL and the new service before editing records

TTL is how long a cached DNS answer may be reused. If you lower it in advance, wait out the previous TTL before the move; lowering it at cutover cannot remove old cached answers. Choose a temporary TTL your DNS provider supports and restore an appropriate normal value once the move is stable.

Confirm the new website is ready, its virtual host recognises the real domain, and HTTPS can serve that name. If changing nameservers rather than individual records, copy the entire required zone to the new provider first. Review DNSSEC with the registrar and DNS provider: an old DS record with unmatched new signing keys can make the whole domain fail validation. Do not change nameservers simply because you only needed a new website IP.

5. Make the intended change in Zone Editor

Use the change sheet to edit the correct record instead of deleting every address that looks unfamiliar.

  1. In the authoritative DNS service, open the domain’s zone. In cPanel this is Zone Editor → Manage.
  2. Find the exact name and record type. Choose Edit, enter the new value supplied by the destination service, review the TTL and save the record.
  3. For a new record, choose Add Record and select the correct type. Check whether the interface expects a complete hostname or appends the domain automatically.

Keep unrelated MX, SPF, DKIM and verification records in place. If you are changing the website, review both the root hostname and www and check whether an old AAAA record could still send IPv6 visitors to the previous server.

6. Verify publication with a browser lookup and a real service test

The edited row in cPanel proves that the control panel saved the value; it does not prove every resolver already returns it.

  1. Use a trusted browser-based DNS lookup, such as Google Admin Toolbox Dig, and search the full record name and type you changed.
  2. Compare the returned value with the change sheet. Check the nameserver results if the answer still appears to come from another provider.
  3. Test the website or email function separately. Give cached answers time to expire according to the previous TTL instead of repeatedly changing the same record.

If the authoritative zone is wrong, restore the recorded previous value. If it is correct but one network is cached, keep the old service available while the previous answer ages out. DNS publication and application health are separate checks.

7. Keep the old service available during the move

DNS caching means not every visitor switches at the same moment. Keep the previous website and email service running for the planned overlap. Verify mail separately, even if the new website looks correct.

If you need to roll back, restore the recorded values and remember that the rollback can be cached too. When the move is stable, return the TTL to a sensible value and update the record of where the domain, DNS, hosting and email are managed.

8. Verify the service and use the rollback sheet if needed

Open both the root domain and www from another connection. Check a deeper page and a form, and make a two-way email test if mail-related records were involved. Compare the DNS answers with the change sheet. A correct IP does not prove that the web server has the right site or certificate.

If the destination is broken, restore the specific old records from your saved values and keep both services available while caches expire. Rolling DNS back does not immediately move every visitor, so pause writes or reconcile data if the old and new sites can both accept orders. Once stable, raise the TTL if you reduced it and keep the final zone snapshot with your hosting notes.

Common questions

Do I edit DNS at the registrar or in cPanel?

Edit it wherever the domain’s authoritative nameservers are hosted. A cPanel zone change has no public effect when the domain uses a different DNS provider.

Why does the site work on my phone but not my computer?

They may use different cached answers or one may prefer IPv6. Compare A/AAAA records and allow the previous TTL to expire before assuming the application is inconsistent.

Further reading

Moving the registration too?

A DNS change and a registrar transfer are separate steps. Check the registration and transfer rules for your extension before making either change.

← Back to all guidesDiscuss your hosting setup ↗