1. Home
  2. Domains
  3. DNS record types
  1. Home
  2. Websites
  3. DNS record types

DNS record types

There are several different types of DNS records that can be added to your domain zone file


What are DNS records

DNS records are essential components of the Domain Name System (DNS), acting as instructions that guide how internet traffic is directed for a domain. Your DNS records are stored on your name servers server in a file known as a Zone File.

Essentially, these records link your domain name to various types of information, such as an IP address for a server (A or AAAA records), a mail server for handling email (MX records), or other services like TXT records for verifying domain ownership and providing essential security features.

Each record type serves a specific function, directing how requests to your domain are handled and ensuring that users are sent to the correct location, whether it’s your website’s server or an email exchange server.

By configuring DNS records, website owners can control the behaviour of their domain, facilitating efficient and secure communication over the internet.


Where can I manage my DNS records

Your DNS records are stored on your name servers. Therefore, in order to manage your DNS records, you will need to contact your name server provider. This is typically your domain register or you web hosting provider.

If you are using our name servers:

  • ns1.easyhosting.com
  • ns2.easyhosting.com
  • ns3.easyhosting.com
  • ns4.easyhosting.com

you can manage your DNS records in your Easyhosting Portal, in the Domain Manager.


DNS record types and usage

There are many different types of DNS records that you can use and each has its own use cases. Some common record types are:


A records

An A record, also known as an Address Record, is a type of DNS (Domain Name System) record that maps a domain name directly to the IP address of a computer hosting that domain’s services, such as a website.

example.com   IN A   192.168.2.1

This is one of the most fundamental types of DNS records, used primarily to point your domain to the server where your website is hosted, enabling users to access your site through a familiar domain name rather than having to remember an IP address.

For example, when someone types in example.com into their browser, the DNS lookup will find the A record for example.com and translate it to the server’s IP address like 192.0.2.1. This process allows the user’s browser to connect to the server where the website is hosted. A records are essential for directing internet traffic to the correct location, making them a foundational element of the web’s navigation system.

A zone file must include at least one A record to be valid. Also, the root or “blank” record must be an A record.


AAAA records

A AAAA record, pronounced as “quad-A record,” is a type of DNS (Domain Name System) record similar to the A record, but it maps a domain name to an IPv6 address instead of an IPv4 address.

example.com   IN AAAA   2001:0db8:85a3:0000:0000:8a2e:0370:7334

IPv6 addresses are the newer generation of IP addresses, designed to provide a much larger pool of IP addresses compared to the limited supply of IPv4 addresses. They consist of eight groups of four hexadecimal digits, offering a vastly expanded address space to accommodate the growing number of devices connecting to the internet.

For example, a AAAA record for a domain like example.com might point to an IPv6 address such as 2001:0db8:85a3:0000:0000:8a2e:0370:7334. This record ensures that users whose devices support IPv6 can access the website using the IPv6 protocol, which is increasingly important as the internet continues to grow and evolve.

AAAA records play a crucial role in the transition from IPv4 to IPv6, enabling websites to be accessible via both types of IP addresses and ensuring compatibility across different internet infrastructures.


CNAME records

A CNAME record, short for Canonical Name record, is a type of DNS (Domain Name System) record used to map an alias name to a true or canonical domain name. This record allows you to associate a subdomain with another domain name, rather than directly pointing it to an IP address like A or AAAA records do. CNAME records are particularly useful for pointing multiple domain names to a single IP address, simplifying domain management and allowing for more flexible website architecture.

www.example.com   IN CNAME   example.com

For example, if you have a blog hosted at blog.example.com and you also want to access it through www.blog.example.com, you can create a CNAME record for www.blog.example.com that points to blog.example.com. When someone accesses www.blog.example.com, the DNS system first resolves the name to blog.example.com and then looks up the A or AAAA record for blog.example.com to find its IP address.

It’s important to note that a CNAME record can only be used for subdomains and not for the root domain, mainly because the root domain often has other DNS records attached to it, such as MX records for email, which cannot coexist with a CNAME record. CNAME records are thus a versatile tool in DNS management, enabling more complex domain setups and easier changes to your network infrastructure.


MX records

An MX record, or Mail Exchange record, is a type of DNS (Domain Name System) record that specifies the mail server responsible for receiving email on behalf of your domain. Essentially, it directs email traffic to the correct email server. MX records are crucial for ensuring that emails sent to your domain’s addresses reach the right destination.

example.com   In MX   10   mail.example.com
example.com   In MX   20   backupmail.example.com

MX records include a priority field, allowing for multiple records to be defined for a single domain, facilitating a prioritized list of mail servers. The priority value determines the order in which mail servers are tried; the lower the number, the higher the priority. This setup allows for redundancy and load balancing in email delivery, ensuring that if the primary mail server is unavailable, the next prioritized server will be attempted.

For example, you might have an MX record that points to mail.example.com with a priority of 10 and another pointing to backupmail.example.com with a priority of 20. Email systems attempting to deliver mail to your domain will try to use the server at mail.example.com first. If that server can’t be reached, they will then attempt to deliver to backupmail.example.com.

By properly configuring MX records, domain owners can control how email is routed, use third-party email services, and set up backup mail servers to ensure reliable email communication.


TXT records

TXT records are a type of DNS (Domain Name System) record that provides text information to sources outside your domain. These records can serve various purposes, including verifying domain ownership, ensuring email security, and implementing other policies. Unlike A, AAAA, or MX records, which are used for specific technical purposes like directing internet traffic or handling emails, TXT records are versatile and can store any text-based information that the domain administrator wishes to provide publicly.

example.com   IN TXT   "This is a TXT record"

One common use of TXT records is in email authentication methods such as SPF (Sender Policy Framework), DKIM (DomainKeys Identified Mail), and DMARC (Domain-based Message Authentication, Reporting, and Conformance). These protocols use TXT records to verify that an email comes from a legitimate source and to provide instructions on how to handle messages that don’t pass the authentication check. For example:

  • SPF records help prevent email spoofing by specifying which mail servers are allowed to send emails on behalf of your domain.
  • DKIM records provide a way to validate a domain identity through cryptographic authentication, ensuring that the email content hasn’t been tampered with in transit.
  • DMARC records build on SPF and DKIM, allowing domain owners to specify how receiving email servers should treat emails that fail SPF or DKIM checks.

Another use of TXT records is for domain verification processes by various services, like Google Workspace or Microsoft 365, which may ask domain owners to add a specific TXT record to their DNS settings as proof of control over the domain.

TXT records can also be used for other miscellaneous purposes, such as providing general information about a server, implementing network security policies, or even indicating software versions.

The flexibility of TXT records makes them a powerful tool for domain administrators to communicate necessary information and policies in a standardized way that can be easily accessed and interpreted by automated systems.


SRV records

An SRV record, short for Service Record, is a type of DNS (Domain Name System) record that specifies the location of a server for specific services, such as Voice over IP (VoIP), instant messaging, and other Internet services. Unlike more traditional DNS records that direct traffic to a server based on the domain name, SRV records provide information on the availability of services at specific ports on a server. They play a critical role in the operation of certain protocols that require service discovery.

An SRV record contains the following essential information:

  • Service: The name of the service provided.
  • Protocol: The protocol used by the service, such as TCP or UDP.
  • Domain: The domain name offering the service.
  • Priority: Similar to MX records, this determines the order in which the server is to be used. A lower number indicates a higher priority.
  • Weight: When multiple SRV records have the same priority, the weight value determines the server selection mechanism, helping to distribute the load across multiple servers.
  • Port: The port number on which the service is running.
  • Target: The host name of the machine providing the service, which must have an A or AAAA record in the DNS.

For example, an SRV record might be used to direct email traffic to an email server without requiring a specific subdomain or to connect users to a specific server for a multiplayer online game. They are particularly useful in environments that require more complex network configurations and service discovery mechanisms, such as cloud services, enterprise networks, and online gaming. SRV records enhance the flexibility and control over traffic routing within the DNS system, facilitating more advanced networking setups.


Still need help?

If you are in need of assistance, you can contact our support staff using one of the following methods:

Send us an email – 24/7/365

Live Chat – 24/7/362

Access our Live Chat support team from your Easyhosting Portal

Phone Support – Monday to Friday, 9:00am to 7:00pm EST

Call one of our Phone Support team members anytime between 9:00am and 7:00pm, eastern time at 1-888-390-1210.

Updated on March 28, 2024

Related Articles