...
Royalhost
DirectAdmin

How to Create an A Record in DirectAdmin: Step-by-Step Guide

How to create an A record in DirectAdmin

Learning how to create an A record in DirectAdmin is important when you need to connect a domain or subdomain to a web server. An A record tells the DNS system which IPv4 address should receive visitors for a specific hostname.

For example, you may need to point example.com to your hosting server, connect www.example.com to a website, or send app.example.com to a separate server. You can manage these records through the DirectAdmin DNS Management section when DirectAdmin is responsible for your domain’s DNS.

In this guide, you will learn what an A record does, how to create an A record in DirectAdmin, how to point a domain to an IP address, how to add an A record for a subdomain, and how to check whether the change is working.

If you are looking for hosting with DirectAdmin, explore RoyalHost DirectAdmin web hosting. RoyalHost provides hosting plans with a browser-based control panel for managing domains, files, databases, email, SSL, and DNS records.

What Is an A Record?

An A record is a DNS record that connects a domain name or hostname to an IPv4 address. The letter “A” means “Address.”

People use domain names because they are easy to remember. Servers, however, communicate through IP addresses. DNS works as the system that connects a readable domain name to a numerical server address.

For example, an A record may look like this:

example.com.    A    192.0.2.10

In this example, visitors who request example.com are directed to the server using the IPv4 address 192.0.2.10.

An A record can also point a subdomain to a server:

app.example.com.    A    192.0.2.10

The IP address in these examples uses a documentation-only range. You must replace it with the real IPv4 address provided by your hosting company or server administrator.

You might be interested: What Is Host A Record? Everything about DNS A Record

When Do You Need to Create an A Record?

You may need to create an A record in DirectAdmin in several common situations:

  • You moved your website to a new hosting server.
  • You want to point a domain to your DirectAdmin hosting account.
  • You want to connect a subdomain to a separate server.
  • You are setting up a web application, store, or control panel.
  • You are connecting a mail, VPN, game, or API subdomain to an IPv4 address.
  • You changed your server IP address.
  • You want to create a hostname such as app.example.com or server.example.com.

In many cases, DirectAdmin creates the primary domain’s DNS records automatically when you add a domain. You usually need to create a new A record only when the required hostname does not already exist or when it must point to a different server.

Before You Create an A Record in DirectAdmin

Before changing DNS, confirm a few details. A small mistake can send visitors to the wrong server or make a website temporarily unavailable.

1. Find the Correct IPv4 Address

Ask your hosting provider for the correct server IPv4 address. You may also find it in your hosting welcome email, account dashboard, or DirectAdmin account information.

Do not guess the IP address. Using an incorrect address can point your domain to another website, an inactive server, or a server that does not contain your files.

2. Confirm Where Your DNS Is Managed

DirectAdmin can manage DNS only when your domain is using the nameservers connected to that DirectAdmin server.

If your domain uses Cloudflare nameservers, you must create or edit the A record in Cloudflare. If your domain uses your registrar’s nameservers, you may need to edit the record in the registrar’s DNS panel instead.

Changing a record inside DirectAdmin does not affect public DNS when another provider is authoritative for the domain.

3. Check Existing Records First

Before adding a new record, look for an existing A record with the same hostname. For example, check whether an A record already exists for:

  • @ or the root domain
  • www
  • mail
  • app
  • api

Two conflicting records can cause inconsistent results. In some cases, multiple A records are intentional for load balancing, but you should not delete or add records without understanding the existing setup.

How to Create an A Record in DirectAdmin

The exact appearance of DirectAdmin may differ slightly between skins and versions. The names can also change between the Evolution skin and older interfaces. However, the general process is the same.

Step 1: Log In to DirectAdmin

Open your DirectAdmin login address and sign in with your hosting account username and password.

Your hosting provider usually sends the DirectAdmin URL in the welcome email. It may use a secure address with a custom port, such as:

https://your-server-hostname:2222

Use the exact address supplied by your hosting provider. Do not share your DirectAdmin password with anyone.

Step 2: Open the User Level

DNS records for an individual hosting account are normally managed at the User Level.

If you are an administrator or reseller, use the level selector at the top of the interface and switch to the correct user account. DirectAdmin separates Admin, Reseller, and User functions, so the DNS option may not be visible at the wrong level.

Step 3: Open DNS Management

From the DirectAdmin dashboard, open Account Manager and select DNS Management.

Depending on your DirectAdmin skin, you may see DNS Management directly on the main page. The important section is the DNS zone editor for your domain.

Step 4: Select the Correct Domain

If your account contains more than one domain, select the domain that you want to edit.

Make sure you choose the correct domain before adding the record. A DNS change applies only to the selected domain zone.

Step 5: Review the Existing DNS Zone

DirectAdmin will display the current DNS records. You may see A, AAAA, CNAME, MX, TXT, NS, and other record types.

Look for the hostname you want to edit. If the record already exists, you may need to edit it instead of creating another one.

For example, if you want to point the main domain to a new server, check whether an existing root A record is already listed. If you want to connect www.example.com, check the www record.

Step 6: Click Add Record or Add A Record

Click Add Record, Add A Record, or the equivalent button shown by your DirectAdmin interface.

Some versions display a general form where you first choose the record type. Other versions show separate fields for common record types. Select A as the record type.

Step 7: Enter the Hostname

The hostname field determines which part of the domain the record will control.

GoalHostname or NameExample Result
Root domain@, blank, or the domain nameexample.com
WWW versionwwwwww.example.com
Application subdomainappapp.example.com
API subdomainapiapi.example.com
Mail hostnamemailmail.example.com

For the root domain, DirectAdmin may accept @, a blank field, or the full domain name. Use the format shown by your interface. Do not enter the complete domain twice if DirectAdmin automatically appends the domain name.

For example, if the panel automatically adds .example.com, entering app is correct. Entering app.example.com could create an incorrect hostname such as app.example.com.example.com.

Step 8: Enter the IPv4 Address

Enter the IPv4 address supplied by your hosting provider.

A valid IPv4 address contains four numerical sections separated by dots:

203.0.113.25

Do not include:

  • http:// or https://
  • A port number such as :8080
  • A path such as /website
  • A cryptocurrency wallet address
  • An IPv6 address in an A record field

If you need to connect an IPv6 address, create an AAAA record instead. An A record is designed for IPv4 addresses.

Step 9: Review the TTL Value

TTL means “time to live.” It tells DNS resolvers how long they may cache the record before checking again.

For a normal website connection, you can usually keep the default TTL provided by DirectAdmin. If your hosting provider gives you a specific TTL, use that value.

Do not change the TTL repeatedly while troubleshooting. Different DNS resolvers may still have the previous value cached until the old TTL expires.

Step 10: Save the New A Record

Click Save, Add, or the confirmation button shown by DirectAdmin.

After saving, return to the DNS zone and confirm that the record appears with the correct hostname, type, and IPv4 address.

At this point, the record has been added to the DirectAdmin DNS zone. Public DNS resolvers may need additional time before they return the new value.

You might be interested: Royalhost Web Hosting Services Are Now Available with the DirectAdmin Control Panel

How to Point the Root Domain to an IP Address

To point the main domain to a server, create an A record for the root hostname.

A typical configuration looks like this:

Name: @
Type: A
Value: 203.0.113.25
TTL: Default

Depending on the DirectAdmin version, the name may be blank or may appear as the full domain name. The final result should represent:

example.com.    A    203.0.113.25

If your domain already has an A record pointing to an old server, edit that record or remove the old record only after confirming that the new server is ready.

How to Add an A Record for a Subdomain

Creating an A record for a subdomain follows the same process.

Suppose you want to connect app.example.com to the IPv4 address 203.0.113.25. Enter:

Name: app
Type: A
Value: 203.0.113.25

The result should be:

app.example.com.    A    203.0.113.25

This is useful for web applications, dashboards, APIs, staging environments, game servers, and other services that run on a separate hostname.

Creating the DNS record does not automatically install an application or configure the server. The destination server must also be configured to accept requests for that hostname.

Should You Create an A Record for www?

The www hostname can use either an A record or a CNAME record. The best choice depends on your current DNS structure and hosting instructions.

An A record for www may look like this:

www.example.com.    A    203.0.113.25

Another common setup uses a CNAME:

www.example.com.    CNAME    example.com.

Do not create an A record and a CNAME record for the same hostname. DNS does not allow a hostname to be both a CNAME and another record type at the same time.

If your hosting provider recommends a specific setup, follow that instruction. Otherwise, check the existing zone before choosing between an A record and a CNAME.

A Record vs AAAA Record vs CNAME

These DNS records are often confused because they all help connect names to services.

Record TypePurposeTypical Value
AConnects a hostname to an IPv4 address203.0.113.25
AAAAConnects a hostname to an IPv6 address2001:db8::10
CNAMECreates an alias to another hostnameexample.com.
MXSpecifies mail servers for a domainmail.example.com.
TXTStores text for verification and email policiesv=spf1 ...

Use an A record when you have an IPv4 address. Use an AAAA record for IPv6. Use a CNAME when you want one hostname to follow another hostname instead of entering an IP address directly.

How to Check Whether the A Record Works

Saving the record in DirectAdmin is only the first step. You should verify that public DNS returns the expected IP address.

Check with a Browser

Open the domain or subdomain in a browser after saving the record. If the website loads from the new server, the DNS and server configuration may be working.

A browser test alone is not enough. Browsers and operating systems can use cached DNS information, so also check the record directly.

Check with dig on macOS or Linux

Open Terminal and run:

dig +short A example.com

For a subdomain, run:

dig +short A app.example.com

The result should show the IPv4 address that you entered in DirectAdmin.

Check with nslookup on Windows

Open Command Prompt and run:

nslookup example.com

You can also query a specific DNS resolver:

nslookup example.com 8.8.8.8

If the returned address is different, the resolver may still have the old value cached, or the record may be managed by another DNS provider.

Use an Online DNS Checker

An online DNS checker can show how different locations resolve your domain. This can help you understand whether the new A record has reached multiple DNS resolvers.

Remember that different locations may update at different times. A temporary difference does not always mean that the DirectAdmin record is incorrect.

How Long Does DNS Propagation Take?

DNS propagation is the process through which DNS resolvers update their cached information.

Some changes become visible quickly. Others take longer because of TTL values, resolver caches, browser caches, local network caches, or nameserver changes.

Changing an A record is often faster than changing nameservers, but you should still allow time for caching. If the domain used an old IP address recently, some visitors may continue reaching the old server for a while.

Do not keep changing the record every few minutes. Repeated changes make troubleshooting harder and can create different cached results across networks.

Common Problems When Creating an A Record in DirectAdmin

DNS Management Is Not Visible

If you cannot find DNS Management, you may be using the wrong DirectAdmin level, your hosting package may not allow DNS editing, or the domain may not be added to the account.

Switch to the User Level and check Account Manager. If the option is still missing, contact your hosting provider.

The Domain Does Not Use DirectAdmin Nameservers

This is one of the most common reasons an A record appears to have no effect.

If your domain uses Cloudflare, your registrar, or another external DNS service, you must edit the record there. DirectAdmin may show a local zone, but public DNS will continue using the external provider’s zone.

The Domain Still Opens on the Old Server

Check the A record with dig or nslookup. If the old IP appears, wait for the cache to expire or check whether another A record exists.

Also check your local DNS cache, browser cache, VPN, and internet provider resolver. Testing from a different network can help separate local caching from a real DNS problem.

The Record Uses the Wrong Hostname

If you enter the full hostname into a field that automatically appends the domain, DirectAdmin may create a duplicated name.

For example, entering app.example.com in a field that expects only the host could result in an incorrect record. In that field, enter only app.

The Website Loads Without www but Not With www

The root domain and www are separate hostnames. Confirm that www has either an A record or a CNAME pointing to the correct destination.

Also check whether your web server and SSL certificate include both versions.

The A Record Points to an IPv6 Address

An A record accepts an IPv4 address. If you enter an IPv6 address, the record will not work correctly.

Create an AAAA record for IPv6 instead. If you want visitors with both network types to connect, your server and DNS zone may need both A and AAAA records.

There Is a CNAME Conflict

A hostname cannot normally have a CNAME and an A record at the same time. If DirectAdmin rejects the new record, check whether a CNAME already exists for that hostname.

Decide which record type you need before removing anything. If you are unsure, ask your hosting provider for guidance.

How to Set Up Private Nameservers with DirectAdmin

Creating an A record is not the same as creating private or custom nameservers. Private nameservers usually use hostnames such as ns1.example.com and ns2.example.com.

To create private nameservers, you normally need to create A records for the nameserver hostnames and register those nameservers with your domain registrar. You may also need two IP addresses, depending on your server and registrar setup.

You might be interested: How to Set Up Private Name Servers for a Domain

Best Practices for DirectAdmin DNS Records

  • Confirm the IP address before saving any DNS change.
  • Check the existing DNS zone before adding a duplicate record.
  • Use A records only for IPv4 addresses.
  • Use AAAA records for IPv6 addresses.
  • Do not place a protocol, port, or URL path in an A record value.
  • Do not create an A record and CNAME for the same hostname.
  • Keep a record of important DNS changes.
  • Change one related record at a time when troubleshooting.
  • Test the root domain and www version separately.
  • Confirm which provider controls your nameservers.
  • Allow time for DNS caches to update.
  • Keep your DirectAdmin account protected with a strong password.

If you manage a dedicated server or need help with advanced DNS configuration, RoyalHost also provides DirectAdmin server management and DNS configuration support.

Can You Create an A Record Without Changing Nameservers?

Usually, no. The DNS provider that receives queries for your domain controls the public records.

If your domain uses RoyalHost nameservers, you can manage the zone through the DirectAdmin account when DNS management is enabled. If the domain uses Cloudflare nameservers, you must create the record in Cloudflare instead.

You can keep your current nameservers and create the A record at the current DNS provider. You do not always need to move DNS to DirectAdmin. The important point is to edit the authoritative DNS zone.

What Happens After You Point a Domain to a New Server?

An A record only tells DNS where to send the request. The destination server must also be ready to answer for the domain.

After creating the record, check the following:

  • The domain has been added to the hosting account.
  • The website files exist in the correct document root.
  • The web server is configured for the domain.
  • The database and application settings use the correct hostname.
  • The SSL certificate covers the domain and www version.
  • The firewall allows normal web traffic.
  • The email records still point to the correct mail provider.

Changing an A record does not automatically move website files, databases, email accounts, or SSL certificates. DNS is only one part of a hosting migration.

Frequently Asked Questions

What is an A record in DirectAdmin?

An A record in DirectAdmin connects a domain or hostname to an IPv4 address. It tells DNS which server should receive requests for that hostname.

How do I create an A record in DirectAdmin?

Log in to DirectAdmin, open Account Manager, select DNS Management, choose your domain, click Add Record or Add A Record, enter the hostname and IPv4 address, and save the change.

What should I enter in the Name field for the main domain?

Depending on the DirectAdmin version, the root domain may use @, a blank field, or the full domain name. Follow the format displayed by your DNS editor and avoid entering the domain twice.

What IP address should I use for an A record?

Use the public IPv4 address provided by your hosting company or server administrator. Do not use a private address such as 192.168.x.x for a public website.

Can I use an IPv6 address in an A record?

No. Use an AAAA record for an IPv6 address. A records are designed for IPv4 addresses.

How do I create an A record for a subdomain?

Open DNS Management, add a new A record, enter only the subdomain label such as app, and enter the server’s IPv4 address. The result will be app.example.com.

Why is my A record not working?

Common causes include DNS propagation, an incorrect IP address, a duplicated hostname, an external DNS provider, a wrong DirectAdmin level, or a server that is not configured for the domain.

Should www be an A record or a CNAME?

Either can work. Use the setup recommended by your hosting provider. Do not create both an A record and a CNAME for the same hostname.

Can I edit DNS in DirectAdmin if my domain uses Cloudflare?

You may see a local DNS zone in DirectAdmin, but public DNS is controlled by Cloudflare when its nameservers are active. Create the A record in Cloudflare in that situation.

How long does an A record take to update?

The timing depends on TTL values, resolver caches, and the previous DNS configuration. Some changes appear quickly, while others take longer. Nameserver changes can require more time than a normal A record update.

Does creating an A record move my website automatically?

No. An A record only directs traffic to an IP address. You must also configure the server, upload the website, create databases, install SSL, and confirm that the web server accepts the domain.

Can RoyalHost help with DirectAdmin DNS configuration?

Yes. RoyalHost offers DirectAdmin hosting and server management services. If you are unsure which record to create or which IP address to use, contact the support team before changing important DNS records.

Conclusion: Create Your DirectAdmin A Record Correctly

Creating an A record in DirectAdmin is usually a simple process. Log in to the User Level, open DNS Management, choose the correct domain, add an A record, enter the correct IPv4 address, and save the change.

The most important step is confirming where your DNS is actually managed. If your domain uses external nameservers, edit the record with that DNS provider instead of DirectAdmin.

After saving the record, verify it with dig, nslookup, or an online DNS checker. Then allow time for caches to update and confirm that your web server, SSL certificate, and domain configuration are ready.

If you want a control-panel hosting environment with DirectAdmin, explore RoyalHost web hosting plans. You can manage your website, domains, DNS records, email, databases, and other hosting settings from one account.

For more information about RoyalHost services, visit the RoyalHost website or contact the support team before making a major DNS change.