# Worked example: moving a live site to our DNS

> Step by step: move a live website and Google Workspace mail to our DNS without an outage.

A domain currently hosted elsewhere, with a website and Google Workspace mail. The goal is to move DNS without an outage.

1. **Record what exists.** Read the current zone at the old provider. You need every A, CNAME, MX and TXT record — especially the mail ones.

2. **Recreate the web records.**

   ```http
   POST /zones?domainName=apiname.com
   {"zoneStruct":{"name":"@","type":"A","ttl":3600,"contents":["203.0.113.10"]}}

   POST /zones?domainName=apiname.com
   {"zoneStruct":{"name":"www","type":"CNAME","ttl":3600,"contents":["apiname.com"]}}
   ```

3. **Recreate the mail records.** Getting these wrong is what takes mail down.

   ```http
   POST /zones?domainName=apiname.com
   {"zoneStruct":{"name":"@","type":"MX","ttl":3600,
    "contents":["1 aspmx.l.google.com","5 alt1.aspmx.l.google.com","10 alt2.aspmx.l.google.com"]}}

   POST /zones?domainName=apiname.com
   {"zoneStruct":{"name":"@","type":"TXT","ttl":3600,
    "contents":["v=spf1 include:_spf.google.com -all"]}}
   ```

4. **Verify.** `GET /zones?domainName=apiname.com` and compare against your notes from step 1, line by line.

5. **Switch delegation.**

   ```http
   POST /zones/apply?domainName=apiname.com
   ```

   Log `previousNameServers` from the response.

6. **Wait.** Up to 48 hours for full propagation. Both old and new name servers answer during this window, so a correct zone means no visible outage.
