DigitalOceanTutorial2 min read

How Do I Use DigitalOcean DNS to Manage My Domain?

Move your domain DNS to DigitalOcean for centralized record management, automatic Droplet linking, and fast propagation.

Server racks and cloud infrastructure

Why Use DigitalOcean DNS?

Managing DNS in the same panel as your Droplets simplifies infrastructure. You can point records at Droplets by name instead of IP, add subdomains for staging environments, and configure email (MX), verification (TXT), and CDN (CNAME) records — all in one place.

Step 1 — Add Your Domain

Go to Networking → Domains → Add Domain. Enter your domain name. If you select a Droplet during setup, DigitalOcean creates A records for @ and www pointing to that Droplet automatically.

Step 2 — Update Nameservers at Your Registrar

At your domain registrar (where you bought the domain), replace the existing nameservers with DigitalOcean's:

  • ns1.digitalocean.com
  • ns2.digitalocean.com
  • ns3.digitalocean.com

Propagation typically takes 15 minutes to a few hours. Your site may be briefly unreachable during the switch if old and new records conflict — plan the change during low-traffic hours.

Step 3 — Manage DNS Records

Click your domain to view and edit records:

  • A — maps a hostname to an IPv4 address (e.g. @ → 164.90.x.x)
  • AAAA — maps to IPv6
  • CNAME — aliases one hostname to another (e.g. www → @)
  • MX — mail server routing
  • TXT — verification, SPF, DKIM records
  • NS — subdomain delegation

Step 4 — Create Subdomains

Add an A record with hostname staging pointing to a staging Droplet's IP. Now staging.yourdomain.com resolves independently from production. You can also use CNAME to point api at a load balancer hostname.

Step 5 — Link Records to Droplets by Name

When creating A records, you can select a Droplet from a dropdown instead of typing an IP. If you rebuild the Droplet with a new IP, update the record once — or use a floating IP that never changes.

Common Record Setups

  • Website: A @ → Droplet IP, CNAME www → @
  • Email (Google Workspace): MX records per Google's docs, TXT for SPF/DKIM
  • App Platform: CNAME @ → your-app.ondigitalocean.app

DigitalOcean DNS is free for domains using their nameservers — no per-query charges.