Subdomains and wildard * in DNS: only the subdomain part, or the entire domain name?

Rog

Verified User
Joined
Sep 27, 2016
Messages
20
I recently moved some domains to a DirectAdmin server, and the DNS stuff was already set up for me. However I'm wondering about subdomain DNS records.

There are A and MX and NS records for the main domain, e.g. "example.com." (including point at the end) and also a bunch of common subdomains, like www, ftp, mail, and so on.

What I'm wondering about, should those subdomain entries include the entire domain name? Currently they look like this: screenshot

But shouldn't that be "www.example.com." and "mail.example.com." etc? Or are partial names (just the subdomain part like "www") automatically interpreted as "www.example.com." ?

Also, if I want to add a wildcard subdomain record, so that <anything>.example.com resolves to example.com, should I add an entry like this:

Code:
*    CNAME    example.com

or like this:

Code:
*.example.com    CNAME    example.com
 
Back
Top