Sign inCreate server
Domains & DNS

DNS Record Types Explained: A, CNAME, MX, TXT and SRV

Understand what each DNS record does (A, AAAA, CNAME, MX, TXT, SRV, CAA and NS), when to use each one and how to look them up with simple commands.

7 min read#dns record types#a record vs cname#what is an mx record#txt record spf#srv record minecraft#tipos de registros dns#diferencia a y cname#qué es un registro txt

A DNS record is one line in your domain's zone that tells the internet something about a name: where it lives, where its email goes or which service answers on it. The ones you will use most are A (name to IPv4 address), CNAME (name to another name), MX (email), TXT (text and verifications) and SRV (a service on a port). This guide explains each one with examples from SolumeCore services.

The record types at a glance

Type What it does Typical value
A Points a name to an IPv4 address 203.0.113.10
AAAA Points a name to an IPv6 address 2001:db8::10
CNAME Makes a name an alias of another name target.example.net
MX Says which server receives the email of the domain Priority 10 and server mail.example.com
TXT Stores text: email policies and ownership checks v=spf1 +a +mx ~all
SRV Says which host and port offer a service Priority, weight, port and target
CAA Says which certificate authorities may issue SSL for the domain 0 issue "letsencrypt.org"
NS Says which nameservers answer for the domain ns1.example.net

The DNS zone editor of a web hosting lets you add the first seven types. It shows NS and SOA records of the root with a lock, because changing them could disconnect the whole domain. See Edit DNS records from the dashboard.

Name and TTL

Every record has a name and a TTL:

  • The name is relative to your domain. @ means the domain itself, www means www.yourdomain.com and shop means shop.yourdomain.com. Some providers want the full name, so follow what the form shows.
  • The TTL (time to live) is how long other networks keep a copy of the answer. A short TTL such as 5 minutes makes changes show up sooner; a long one such as 1 day reduces queries once everything is stable.

A and AAAA: name to address

An A record is what makes yourdomain.com open your server. It holds an IPv4 address. An AAAA record does the same with an IPv6 address.

A web hosting from SolumeCore uses A records for the domain, www, cpanel, webmail and mail. A VPS needs one A record with its IP address, as shown in Point a domain to your VPS.

CNAME: an alias for another name

A CNAME says "this name is the same as that other name". It is how many services ask you to connect a domain, because they can change their address without you touching anything. Two rules:

  • A CNAME cannot sit on the root of a domain (@), because the root also needs other records such as MX and NS. The dashboard rejects it with "A CNAME can't go on the domain itself". Use an A record there.
  • A name with a CNAME cannot have other records at the same name.

SolumeCore uses CNAME records to connect your domain to a game server or to an app. The values come from the dashboard, as in Connect a domain to a SolumeCore service.

MX: where the email goes

An MX record has a priority and a mail server. When someone writes to you, the sender tries the server with the lowest priority number first and falls back to the next one if it does not answer. To move your email to another provider, you replace the MX records with the ones the provider gives you. In a web hosting, the templates for Google Workspace and Zoho Mail do it in one click.

TXT: text, email policies and verification

A TXT record holds plain text. It is used for:

  • SPF: says which servers may send email for your domain, for example v=spf1 +a +mx +ip4:203.0.113.10 ~all.
  • DKIM: publishes the key that proves your emails were signed by you.
  • DMARC: tells receivers what to do with email that pretends to be yours, in a record named _dmarc.
  • Verification: a service asks you to publish a text to prove the domain is yours. When you connect your own domain to an app, the TXT named _solume-verify works like that.

A domain should have a single SPF record. If you use several services to send email, merge them into one record instead of creating two.

SRV: a service on a port

An SRV record points a service name to a host and a port. Its name has the form _service._protocol. Minecraft Java looks for _minecraft._tcp to learn which port a server uses, which is why players of a server with a custom domain do not type the port. An SRV record has four values: priority, weight, port and target.

CAA: who may issue your certificates

A CAA record limits which certificate authorities can issue SSL for your domain. It has flags, a tag (issue, issuewild or iodef) and a value. If you add one, make sure it allows the authority that issues your certificates; otherwise new certificates will fail.

NS: who answers for the domain

NS records list the nameservers of the domain. They are set at your registrar. Pointing them to the nameservers of your hosting gives you the DNS zone editor in the dashboard; keeping another DNS provider means you edit the records there.

Look up a record yourself

bash
dig +short yourdomain.com A
dig +short yourdomain.com MX
dig +short yourdomain.com TXT
dig +short _minecraft._tcp.play.yourdomain.com SRV
dig +short yourdomain.com NS
powershell
Resolve-DnsName yourdomain.com -Type A
Resolve-DnsName yourdomain.com -Type MX
Resolve-DnsName yourdomain.com -Type TXT
nslookup -type=SRV _minecraft._tcp.play.yourdomain.com
Resolve-DnsName yourdomain.com -Type NS

Troubleshooting

"Check the value: it doesn't match this record type"

The editor checks that the value fits the type. An A record needs an IPv4 address, a CNAME a name, and an MX a priority number and a server name.

My email stopped working after I changed records

You may have replaced or deleted the MX or SPF records. Restore them, or apply the template of your email provider so they are created together.

Two records for the same name behave strangely

A name can have several A records, but not a CNAME together with other types. Remove the extra or conflicting one.

FAQ

What is the difference between an A record and a CNAME?

An A record points a name to an IP address. A CNAME points a name to another name, which then leads to an IP address. Use A for the root and for servers you control, and CNAME when a service gives you a name to point to.

Why can't I put a CNAME on my root domain?

Because the root already has records that must coexist, such as MX and NS, and a CNAME cannot share a name with other records.

What is a TXT record used for?

Mainly for email policies (SPF, DKIM, DMARC) and to prove you own a domain to a third-party service.

Do I need an AAAA record?

Only if your server has an IPv6 address and you want visitors to reach it over IPv6. The A record is enough to make the domain work.

Putting your domain to work? See SolumeCore web hosting.

Was this article helpful?
DNS Record Types Explained: A, CNAME, MX, TXT and SRV