Domain IP Lookup

The records you will meet in nearly every zone

AHostname to an IPv4 address
AAAAHostname to an IPv6 address
CNAMEHostname to another hostname
MXDomain to its mail servers, by priority
TXTDomain to arbitrary text -- SPF, DKIM, verification
NSDomain to the nameservers that answer for it
DNS Fundamentals

DNS Wildcard Records Explained: How They Match Subdomains

4 min read

A wildcard DNS record uses an asterisk label to provide answers for names that do not have a more specific record in a zone. It can be useful when an application accepts many tenant subdomains or when a service intentionally handles a broad set of hostnames. A wildcard is not a universal rule that overrides every explicit record, and its behavior depends on DNS name existence and the requested record type. It can also create surprising results by making misspelled or unintended subdomains resolve somewhere instead of failing clearly. Use it only when the application and security model are designed for that breadth.

How wildcard matching works

A wildcard label is written as an asterisk at a particular name level, commonly *.example.com. It can supply data for certain names beneath that point when no closer matching data exists. It does not mean that every descendant at every depth is automatically created in the way a filesystem wildcard might suggest. Existing names, delegations, and empty non-terminal nodes affect the result. Record type also matters: a wildcard A record does not automatically create every possible MX, TXT, or AAAA record for every subdomain. Test the names and record types your application expects rather than assuming one wildcard covers all DNS behavior.

Configuration choiceLikely effect
Explicit record for a nameProvides that name's configured data
Wildcard at a parentCan answer eligible otherwise-unconfigured names
Wildcard A onlyDoes not imply wildcard email or TXT policy
No matching recordMay return no data or a name error depending on zone state

A common use case is multi-tenant hosting where each customer receives a subdomain and all such names route to the same application edge. The application then inspects the hostname and determines which tenant or site to serve. DNS only gets the request to an endpoint; it does not validate that the requested tenant exists or that the requester may access it. The application must enforce its own routing and authorization rules. If unknown subdomains fall through to a default site, ensure that default does not expose administrative tools, debug content, or another customer's data.

Operational and security considerations

Wildcards can hide typos during testing because a misspelled name may still resolve. They may also cause certificate automation to request names you did not intend to publish. Email-related wildcards need special care: a wildcard address record should not be mistaken for a deliberate mail policy, and catch-all mail behavior belongs to the mail system rather than being created by DNS alone. Inventory explicit names and delegated subdomains before introducing a wildcard. Document who owns the behavior and what the receiving application does with unexpected hostnames.

  • Use wildcard records only for names your application is prepared to handle.
  • Keep explicit records for services that need distinct routing or policy.
  • Test unknown and malformed subdomains, not only expected tenant names.
  • Do not treat wildcard DNS as access control or tenant authorization.
  • Review certificate, email, and monitoring implications before deployment.

Troubleshooting a wildcard answer

When an unexpected subdomain resolves, inspect the zone for a wildcard at the relevant level and check whether a more specific record or delegation exists. Query the exact name and record type, then compare it with the wildcard target. If a wildcard seems not to apply, examine whether an existing node changes wildcard synthesis for that branch of the DNS tree. Provider interfaces can abstract these details, so confirm how the service implements wildcard records. After removing or changing a wildcard, allow for caches to expire and test both previously expected names and names that should now fail.

Wildcards are a focused tool, not a shortcut around hostname inventory. They work best when a product intentionally serves a variable name space and the application performs safe, explicit host routing. For foundational context, see DNS record types explained and what a CNAME does. A public DNS lookup can confirm what a resolver returns for a chosen name, while application tests confirm that the endpoint treats that name correctly.

Test both expected and unexpected names

A wildcard deployment should be tested with more than one known-good tenant name. Check a name that should be handled, a name that should have an explicit override, and a random name that should not exist. Then inspect both DNS answers and the application's response. A wildcard can route an unknown label to the service, but the application should return a safe not-found response rather than creating an accidental default account or leaking configuration. Repeat tests after adding explicit records and delegations, because DNS tree structure can change which wildcard data applies. Document the intended name pattern so future operators know whether a newly resolving subdomain is expected or a configuration surprise.

Need to check a domain's public DNS addresses? Use the Domain IP Lookup tool.

wildcard DNSDNS recordssubdomains