Set up domain: connect domain to hosting
For your website and email to be reachable under your domain, the nameservers and DNS records must point to the correct hosting. This guide shows you both setup methods, explains A, AAAA, CNAME, MX and TXT records, and helps with SSL, email security, propagation and troubleshooting.
Marco | 30 Sept 2026
If the domain and hosting are with the same provider, the connection is usually established automatically. With separate providers you either change the name servers or set individual DNS records. Existing entries should be backed up, and the website, e‑mail, HTTPS and DNSSEC should then be checked separately.
The technical notes were checked on 30 September 2026. User interfaces and specific DNS values vary between providers. Therefore always take the target values from your hosting and email provider's documentation.
What does “set up a domain” mean?
A registered domain does not automatically point to your website. Using the Domain Name System you specify which web server delivers the site and which mail servers accept messages for your addresses. For this you either manage individual DNS records or hand over complete DNS management to other nameservers.
If you don't yet own a domain, you can first check availability and find suitable offers in the Domain comparison.
Is your desired domain still available?
Enter a name or a full domain, e.g. myshop or myshop.co.uk.
Two ways: automatic setup or configure DNS yourself
Domain and web hosting with the same provider
If you order a domain and web hosting together, the provider will usually set up the website, DNS and often email automatically. Usually you only need to assign the domain to a webspace or project in the customer area. This option is straightforward and suitable for beginners.
Domain and web hosting with different providers
If the domain is at provider A and the hosting at provider B, the host will provide either its own nameservers or specific DNS target values. You enter these at the domain provider. The older article on Connecting external domains describes the basic principle; the following guide fully places today's common procedures in context.
Change nameservers or set individual DNS records?
A nameserver change transfers the entire DNS zone to the new provider. You then maintain all entries for website, email and verifications there. This is convenient if one provider should manage everything. Individual DNS records are more flexible: the DNS zone stays with the domain provider while you only change web or mail targets.
| Option | Advantage | Risk |
|---|---|---|
| Change nameservers | Hosting provider can fully manage the zone | Existing mail and verification records must be included in the new zone |
| Change DNS records | Website and email can remain with different services | Values must be manually maintained correctly |
Document all existing records. If MX, SPF, DKIM or verification entries are missing after the change, the website may continue to work while e-mails fail or are no longer reliably delivered.
Key DNS records

| Type | Function | Typical example |
|---|---|---|
| A | maps a name to an IPv4 address | @ → 192.0.2.10 |
| AAAA | maps a name to an IPv6 address | @ → 2001:db8::10 |
| CNAME | makes a name an alias of another hostname | www → example.com |
| MX | specifies mail servers and priority | @ → mail.example.net |
| TXT | stores verification and security information | SPF, DKIM or verification value |
We explain the records in detail in the articles about A records, CNAME, MX records and TXT records.
Connecting a domain to external hosting: example
Assume your domain beispiel.de is with the domain provider and your host specifies the IPv4 address 192.0.2.10 for the website. The following values are documentation addresses and are not intended for a real website.
- Log in to the provider that manages the DNS zone.
- Open the domain's DNS or zone settings.
- Set the A record for the root domain with host
@to192.0.2.10. - Set
wwwas a CNAME tobeispiel.de, if your host recommends this. - If using IPv6, also add the specified AAAA record.
- Save the zone and, after the TTL has expired, check the public DNS resolution.
Never copy example IP addresses from a guide into your live zone. The only values that matter are the target values your hosting provider specifies for your particular package.
Set up email correctly
For incoming messages, set the MX records provided by your mail provider. The priority determines which server is contacted first. Remove old MX entries only if the new provider explicitly requires it; a wrong combination can cause delivery issues.
For outgoing email, authentication methods are also important:
- SPF specifies which servers are allowed to send for your domain.
- DKIM attaches a verifiable signature to outgoing messages.
- DMARC defines how recipients should handle failed authentication and where reports are sent.
Use the values from your mail service and do not maintain multiple separate SPF records. Our articles on SPF and DMARC provide further guidance.
Enable an SSL certificate and HTTPS
Once the domain correctly points to the web server, enable an SSL certificate in the hosting panel. Many hosts provide Let’s Encrypt automatically and renew the certificate themselves. Check that both the main domain and www are covered, if both variants are used.
Redirect HTTP permanently to HTTPS. Also decide whether example.de or example.de is the canonical address, and redirect the other variant with a 301. This way you avoid two parallel versions of the same website.
Why DNS changes are not immediately visible everywhere
DNS responses are cached. The TTL indicates how long resolvers may use a record before querying it again. For that reason, different networks may temporarily see different values. Providers often quote periods of up to 24 or 48 hours; for some mail services it can be up to 72 hours.
“Propagation” does not mean that a central change is slowly copied around the world. Usually distributed caches are merely waiting for their stored response to expire. Reduce the TTL well before a planned migration and raise it again after you have successfully checked everything.
Verify domain setup and troubleshoot errors
- Check A, AAAA and CNAME targets publicly using a DNS lookup
- Compare nameservers with the zone expected at the provider
- Test the website via the primary domain and
www - Check HTTPS certificate, redirects and expiry date
- Send test messages and check MX, SPF, DKIM and DMARC
- Remove old or conflicting records
If a change appears not to take effect, first check which nameservers are authoritative. Often a zone is edited at the domain registrar even though the domain already uses the hoster's nameservers. In that case, the change made in the wrong place has no effect. For ongoing monitoring, consider adding DNS monitoring.
Consider DNSSEC when changing nameservers
DNSSEC protects DNS responses with cryptographic signatures against undetected tampering. If DNSSEC is already active, a nameserver change must be coordinated: the new DNS provider generates the appropriate keys, and the corresponding DS record is updated at the registrar or registry. If an old DS record remains, validating resolvers may classify the new zone as invalid. The domain will then appear unreachable despite correct A and MX records.
Do not disable DNSSEC without good reason. First check the order both providers require, and test the signature chain after the change. You can find a detailed introduction in our article on DNSSEC for beginners.
Before the move: short checklist
- Export the DNS zone or document all records.
- Reduce the TTL well in advance.
- Prepare the website and certificate at the destination host.
- Create mail accounts and authentication records.
- Make the change during a quiet maintenance window.
- Only cancel the old service after complete verification.
Frequently asked questions about setting up a domain
Do I have to change the nameservers?
No. You can keep the DNS zone with your current provider and only change individual records. A full nameserver change is useful if the new provider should take over complete DNS management.
Why does the website work but email not?
The website and email use different records. The A or CNAME records may be correct while MX, SPF or DKIM entries are missing or set incorrectly.
How long does a DNS change take?
That depends on TTL and caching. Many changes are visible within minutes, but some resolvers can continue to serve old values for longer. For mail services, follow the timeframes given by the provider.
Do I need a separate web space for www?
No. www is a hostname within your domain and can point to the same website via a CNAME or another appropriate record.
If the domain and hosting are with the same provider, a project assignment is usually sufficient. With separate services you choose between changing nameservers and targeted DNS records. Back up existing records, apply only the values supplied by your providers and check website, email, HTTPS and DNS separately after each change.
Write a comment
- Domain
Tags for this article
More web hosts
More interesting articles
Umlautdomain - How useful is the use of special characters?
Umlautdomain - How useful is the use of special characters? We shed light on the right choice of domain name.
Business Model Typosquatting - speculating with typo domains
What exactly is behind the term Typosquatting and what's the deal with typo domains?