Now a Lovable Certified Expert · see the Lovable partner directory profile
View profileGuide: Domains and DNS
DNS records explained, in plain English.
DNS is the address book of the internet. If you're launching, moving or fixing a website, this guide shows how DNS works, what each record does, and how to avoid the mistakes that take sites and email offline.
- How DNS works
- Record types
- Email and verification
- Common mistakes
The Basics
How DNS works
Computers find each other by numbers. DNS translates your domain name into the address of the server that should answer.
01
You type a domain
A visitor enters example.com in their browser.
02
A resolver asks around
Their internet provider's resolver checks its cache, then asks which nameservers are in charge of example.com.
03
Nameservers answer
The domain's nameservers return the matching record, such as an A record with an IP address.
04
The site loads
The browser connects to that address, and the answer is cached for the record's TTL.
Every record has a TTL (time to live): how long resolvers may cache the answer. A TTL of 3600 means one hour. That's why changes "take time to spread": old answers stay cached until they expire.
Who Does What
Registrar, DNS host and website host
Three different jobs that often get confused, because one company can do all three.
Registrar
Where you rent the domain name and renew it each year.
Examples: GoDaddy, Namecheap, Google Domains (now Squarespace Domains)
DNS host
Where the records live. Set by your nameservers.
Examples: Your registrar, Cloudflare, or your website platform
Website host
Where the site itself runs. DNS records point visitors there.
Examples: Squarespace, WordPress hosts, AI site platforms
Scenario: three companies, one domain
A consultant bought her domain at GoDaddy, moved DNS to Cloudflare for speed, and hosts her site on Squarespace. To connect Squarespace she has to add the records in Cloudflare, not GoDaddy, because that's where her nameservers point.
Nameservers
Nameservers decide who manages your DNS
Your nameservers, set at the registrar, name the one provider whose records count. Changing them moves all DNS management to another platform in one step. It's a powerful switch: every record has to exist at the new provider, or it stops working.
Changing nameservers vs. adding records: many platforms let you choose. Pointing nameservers to them is simpler, but hands over everything. Adding a few A or CNAME records at your current DNS host keeps everything else, like email, exactly where it is.
Scenario: the nameserver switch that broke email
A firm switched its nameservers to its new website platform to make setup easy. The site went live, but email stopped arriving: the MX and SPF records lived only at the old DNS host. Copying them over first would have prevented the outage.
Record Types
The records you'll actually see
Here's what a typical setup looks like inside a DNS provider's dashboard:
DNS records · example.com
+ Add record| Type | Name | Value | TTL | What it does |
|---|---|---|---|---|
| A | @ | 192.0.2.10 | 1 hr | Website (bare domain) |
| CNAME | www | sites.example-host.com | 1 hr | Website (www) |
| CNAME | app | app.example-platform.com | 1 hr | Custom app |
| MX | @ | 1 smtp.example-mail.com | 1 hr | Incoming email |
| TXT | @ | v=spf1 include:_spf.example-mail.com ~all | 1 hr | SPF (one only) |
| TXT | @ | google-site-verification=abc123 | 1 hr | Search Console |
| CNAME | s1._domainkey | s1.dkim.example-mail.com | 1 hr | DKIM signature |
| TXT | _dmarc | v=DMARC1; p=quarantine | 1 hr | DMARC policy |
A record
Points a name to an IPv4 address.
example.com → 192.0.2.10
Use case: Connecting your bare domain to a website host.
AAAA record
Same as A, for IPv6 addresses.
example.com → 2001:db8::10
Use case: Hosts that support IPv6. Optional for most small sites.
CNAME record
Points a name to another name instead of an address.
www → sites.example-host.com
Use case: Connecting www or a subdomain to a platform.
MX record
Tells the world which servers receive your email.
@ → 10 mail.example-mail.com
Use case: Google Workspace or Microsoft 365 email.
TXT record
Holds text that other services read.
@ → "google-site-verification=abc123"
Use case: Site verification, SPF, DKIM and DMARC.
NS record
Names the nameservers in charge of the domain or a subdomain.
@ → ns1.example-dns.com
Use case: Deciding which provider manages your DNS.
CAA record
Lists which companies may issue SSL certificates.
@ → 0 issue "letsencrypt.org"
Use case: Security. A wrong CAA record can block a new site's SSL.
SRV record
Points a specific service to a server and port.
_sip._tls → 100 1 443 sip.example.com
Use case: Phone systems and some Microsoft services.
"@" means the bare domain itself. Example values use documentation addresses and aren't real.
Comparison
A records vs. CNAME records
| A record | CNAME | |
|---|---|---|
| Points to | An IP address | Another hostname |
| Typical use | The bare domain (example.com) | www and other subdomains |
| If the host's IP changes | You must update it | Follows automatically |
| Can share its name with other records | Yes | No, a CNAME must stand alone |
| Allowed on the bare domain | Yes | Usually not (some DNS hosts offer a workaround called flattening or ALIAS) |
Scenario: connecting a domain to a website builder
The platform asks for an A record on @ pointing to its IP address, and a CNAME on www pointing to its hostname. The owner finds an old A record on www from a previous host, deletes it, then adds the CNAME. Both addresses load the new site within the hour.
Subdomains
One domain, many destinations
Every subdomain has its own records, so each one can point to a different platform.
| Subdomain | Points to | Record |
|---|---|---|
| www.example.com | Main website on Squarespace | CNAME |
| app.example.com | Customer app on an AI-built platform | A or CNAME |
| events.example.com | Event landing page | A or CNAME |
| mail.example.com | Email marketing sending domain | CNAME and TXT |
The records that keep email working
MX
Where incoming email is delivered. Wrong or missing MX records mean email stops arriving.
SPF (TXT)
Lists the services allowed to send email as your domain. One SPF record per domain.
DKIM (TXT or CNAME)
A digital signature that proves an email wasn't altered. Each sending service gives you its own.
DMARC (TXT)
Tells inboxes what to do when SPF or DKIM fails, and sends you reports.
Scenario: email landing in spam after a launch
After a new marketing tool was added, invoices started landing in spam. The team had added a second SPF record instead of merging the new sender into the existing one. One merged SPF record fixed it.
TXT Records
Site verification and TXT records
Services like Google Search Console, Bing Webmaster Tools, Microsoft 365 and website platforms ask you to add a TXT record to prove you own the domain. You add the value they give you, wait a few minutes, and click verify.
A domain can hold many TXT records side by side, one per service, and they don't conflict. Leave old verification records in place if the service still uses them. The exception is SPF: keep exactly one.
Conflicts
How DNS conflicts happen
Duplicate A records
Two A records on the same name point visitors to two different hosts, so the site loads one way for some visitors and another way for others.
A CNAME next to other records
A CNAME can't share its name with any other record. Adding one to www while an A record sits there causes errors.
Two SPF records
Adding a second SPF record for a new tool, instead of merging it, makes SPF fail for both.
Leftovers from an old host
Old A records or verification values from a previous platform keep sending some visitors to the old site.
Editing the wrong provider
Records added at the registrar while the nameservers point to Cloudflare are simply ignored.
Myths
Common issues and misconceptions
"I changed it at my registrar, but nothing happened."
Your nameservers probably point somewhere else. Only the provider your nameservers point to counts.
"DNS always takes 48 hours."
Most changes show up in minutes to a few hours. Lowering the TTL before a planned change speeds it up.
"Moving my website moves my email."
Website and email use different records. Each can stay where it is or move separately.
"Turning on the Cloudflare proxy is always fine."
The proxy (orange cloud) can hide your real records and block some platform verifications and SSL. Many platforms ask for DNS only (grey cloud) during setup.
"My SSL is stuck, so the platform is broken."
SSL usually waits on DNS. Check for a leftover A record, a wrong CAA record or a proxy in the way.
Checklist
Before you change any DNS record
- Screenshot or export every existing record before you touch anything.
- Look up your nameservers to confirm which provider is in charge.
- Lower the TTL on records you plan to change a day ahead.
- Copy email records (MX, SPF, DKIM, DMARC) before switching nameservers.
- Change one thing at a time, then confirm it works.
- Remove old records from previous hosts once the new setup is live.
- Re-check site verifications in Google Search Console and other tools.
Moving a site? See our guides to Squarespace migrations, WordPress to Squarespace and migrating to an AI-built site, plus the AI visibility guide for after launch.
FAQ
Common questions
- How long do DNS changes take?
- Usually minutes to a few hours. The often-quoted 48 hours is a worst case. How long a change takes depends on the record's TTL and on how long resolvers cached the old value. Nameserver changes tend to take the longest.
- Where do I edit my DNS records?
- Wherever your nameservers point. That may be your registrar, a service like Cloudflare, or your website platform. Look up your domain's nameservers first, then log in to that provider. Records added anywhere else are ignored.
- Will moving my website break my email?
- Not if you only change the website records (A and CNAME). Email runs on MX, SPF and DKIM records. The risk comes from switching nameservers without copying those email records to the new DNS host.
- Can I have more than one TXT record?
- Yes. A domain can hold many TXT records for different verifications. The exception is SPF: a domain should have only one SPF record, with all your senders merged into it.
- Should I use an A record or a CNAME?
- Use an A record when a platform gives you an IP address, which is common for the bare domain. Use a CNAME when it gives you a hostname, which is common for www and other subdomains. Follow the exact records your platform shows you.
- What is the difference between a registrar and a DNS host?
- The registrar is where you rent the domain name. The DNS host is where its records live. They are often the same company, but they don't have to be, and the nameservers decide which one is in charge.
Next Step
Need help with a domain move?
We'll check your records before anything breaks.
Send us your domain and where you're moving, and we'll map out the records to keep, change and remove so your site and email stay online.
Meet VirtuallyExplore More
What else we build.
Lead Generation Tools
Calculators, assessments and interactive tools that turn your expertise into qualified leads.
Lead Generation Calculators
Valuation, ROI and savings tools that give buyers a useful answer and capture qualified leads.
Assessments
Interactive scoring tools that qualify prospects before the first sales call, with every answer attached.
Visualizers
Interactive product previews that help buyers see the outcome and move forward with confidence.
Landing Pages
High-impact pages and RSVP experiences for campaigns, launches and invite-only events.
Full App Builds
Custom apps with real accounts, data and logic, shipped in weeks, not quarters.
Squarespace Migrations
Move from WordPress, Wix, Webflow or a custom CMS without losing traffic.
AI-Built Websites
Fast custom sites built with AI, with honest pros and cons.
Squarespace Sites
New builds, redesigns and migrations your team can fully own and keep up to date.
LinkedIn Advertising
Managed B2B campaigns that put your offer in front of the exact buyers it was built for.
SEO & AI Visibility
Technical signals and useful content that help buyers find you in search and AI-generated answers.
About Square Migration
The story behind the studio, from Squarespace migrations to lead-generation tools.
