Adding an A Record to Your Domain
An A record (Address record) is the most fundamental DNS record type. It maps a domain name or subdomain to an IPv4 address, telling browsers which server hosts your website.
When You Need an A Record
- Pointing your domain to a web hosting server.
- Pointing a subdomain (e.g.,
shop.yourdomain.com) to a different server. - Setting up a custom hostname for a service.
How to Add an A Record in DirectAdmin
- Log in to DirectAdmin and navigate to DNS Management.
- Select the domain you want to manage.
- Click Add Record.
- Set the Type to
A. - In the Name field, enter the subdomain or use
@for the root domain. - In the Value field, enter the IPv4 address (e.g.,
185.52.0.1). - Set the TTL (Time to Live). The default of 3600 seconds (1 hour) works well for most situations.
- Click Save.
How to Add an A Record in Cloudflare
- Log in to your Cloudflare dashboard and select your domain.
- Go to DNS > Records.
- Click Add record.
- Select A as the type.
- Enter the Name (e.g.,
@for root orshopfor a subdomain). - Enter the IPv4 address.
- Choose whether to enable the Cloudflare proxy (orange cloud) or leave it as DNS only (grey cloud).
- Click Save.
Common A Record Examples
@ → 185.52.0.1– Points the root domain to your server.www → 185.52.0.1– Points the www subdomain to your server.mail → 185.52.0.2– Points the mail subdomain to your mail server.shop → 203.0.113.50– Points a subdomain to a different server (e.g., Shopify).
Troubleshooting
If your A record is not working, verify the IP address is correct, check propagation status using whatsmydns.net, and ensure no conflicting CNAME records exist for the same name.