What Are Domains?

Domains create your address on the internet. When you own a domain, you can tell people to go to the URL mysite.com and they will see whatever content you’ve associated with that domain. Every domain name is matched to an IP address and follows the Domain Name System (DNS).

Without a domain, every website would only be identified by the IP address. Imagine that instead of typing liquidweb.com into your web browser, you had to remember 67.43.15.214, Liquid Web’s IP address. Now imagine remembering strings of numbers for every website you ever want to visit!

example of domain name and site

Domain names make it much easier for people to use the internet. It’s the difference between using latitude and longitude to get somewhere and using a street address to get somewhere.

Let’s use support.liquidweb.com to show how domain names work. Even though it is a little confusing for most people, domain names are technically read from right to left. No one reads them like this when telling you to visit support.liquidweb.com, of course! But reading from right to left creates a funnel: the address goes from the very general (top-level domain) to the very specific.

Top-Level Domains

Top-level domains (TLDs) like com, net, and org hold the right-most position in a domain name. Every country can have their own TLD, too. Every domain name must end with a TLD. In support.liquidweb.com, the TLD is com.

example of TLD

Second-Level Domains (and Beyond)

Whatever is directly to the left of the TLD is called the second-level domain. In the example support.liquidweb.comliquidweb is the second-level domain. Anything to the left of the second-level domain is the third-level domain. In this case, support is the third-level domain. This can go on and on as long as there are more domains to the left. The more levels you use, the more specific your address is.

example of second-level domain

When you purchase a domain name, you buy the right to use a specific TLD and second-level domain. So, you’d buy the right to use mysite.com (or whatever you’d like your domain to be). If you want to add further domains like blog.mysite.com, you don’t have to pay for another domain name. This is considered a subdomain and you can set it up through your domain management system, like cPanel.

example of subdomain

Now that you know the basic concepts surrounding domains, you’re ready to learn how to register your first domain!

Adding a Domain Alias in Cloud Sites

A domain alias is an alternate name for a website. A common use for domain aliases is so mysite.com and mysite.net show the same information. It’s easy to set up domain aliases in Cloud Sites.

When setting up domain aliases in Cloud Sites, remember the alias you create will show the same content as the website where you set up the alias.

  1. Log into the Cloud Sites control panel.
  2. Continue reading “Adding a Domain Alias in Cloud Sites”

What is a FQDN?

What is a Fully Qualified Domain Name (FQDN)?

When working with domains and DNS management understanding what a FQDN is can be very helpful. This article will help explain the concept of a FQDN and a domains different components.

The Parts of a Domain

A domain is made up of a two essential parts, the Top-Level Domain (TLD) and the main Domain Name which is what you register. The other component of domain names are the subdomains. Continue reading “What is a FQDN?”

Enabling DomainKeys Identified Mail (DKIM)

DomainKeys Identified Mail (DKIM) is a way to attach an encrypted digital signature to your email. Like adding an SPF record to your server, DKIM helps prevent email spoofing. Email spoofing is when spammers send email that looks like it’s coming from your email address. Spammers spoof your address to make it more likely that recipients will open spam emails, less likely that messages will be marked as spam, and harder to find the true spam source. If your address is spoofed, your server could get flagged as a spam server and you can have trouble sending legitimate mail, even if you aren’t doing anything wrong. This is commonly known as having a bad mail reputation.

Outgoing DKIM works by generating an encrypted digital signature that is attached to email messages sent by your server. This signature is generated using a public key you save as a DNS record. Theoretically, only you have access to your DNS records, so mail signed using this key should be unmodified and verified as coming from your server. If you don’t use your server to send mail, adding DKIM records to your server will have no effect on your mail reputation.

Using Plesk?

DKIM is not natively supported in Plesk 12. Instead, Plesk uses DomainKeys. If you’d like to use DKIM, it is supported with certain Plesk MailEnable plans. If you specifically need DKIM, contact our Heroic Support team to learn more about MailEnable.

There are three parts to enabling DKIM:

Generating Your DKIM Key

On a cPanel server, generating a DKIM key is easy! cPanel does it for you.

  1. Log into the cPanel account with email accounts where you’d like to enable DKIM. DKIM records are tied to a domain, you each domain you email from will need its own record.
  2. Scroll down to Email and click on Authentication.
    dkim1
  3. On the Email Authentication page, you’ll see two different methods: DKIM and SPF. We recommend using both, but this walkthrough will only cover DKIM. We have a separate article on SPF records. In the DKIM section, click Enable if DKIM is disabled.
    dkim2
  4. Once you enable DKIM, you’ll see a field that shows your current raw DKIM record. This is the public key you need to add to your DNS records. It should look something like this:

    default._domainkey IN TXT "v=DKIM1; k=rsa; p=MIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEAyGm4KfaLQsOiNqfNGT0DDa+XE+TmIyr03F3/AMU8SXFwgItBU/PikYTmIyr07yhQoqlPrSL27l8XHf8AMIIB1LtxU2/490wRkuu9ZorEjRkIXSbev1GyAinBQNa5Rln2S+8AMIIBhZzfkNw7panbVJ0HPREiZAJ5TQEX1LjTqB/nArmNaMXaRUCwmYzGY45z8" eW2BJMM7Ftsj3nOTmIyr0LFSL27l8OaMDdcvpCglrFWoF1dXA78ORuvMSL27l8A5+UWRFBQ4NP6awWYj2LTSyeNeTlafawRk2B3C/dNcwpoLjz3T1wBHctcLnuC13+nMzzyUtgIVgz/7Ka8AMIIBQIDAQAB\;

Copy this record and paste it into a text document to prepare for the next step: adding your DKIM record to DNS.

Adding Your DKIM Key to DNS

Now that you’ve generated your DKIM record, you need to add it to your DNS records. These directions are different depending on where your DNS is hosted:

If you don’t know where your DNS is hosted, read our article on how to find out first!

Your DNS Is Hosted at Liquid Web

If you are using Liquid Web’s nameservers, you can update your DNS records right in your Liquid Web account. Liquid Web’s nameservers are:

  • ns.liquidweb.com
  • ns1.liquidweb.com
  • ns.sourcedns.com
  • ns1.sourcedns.com

As long as your domain is using one of these nameservers, you’re good to go!

  1. Before you begin to add your DKIM record to your Liquid Web account, there is a small amount of formatting to do. The text portion of your DKIM record should look similar to this:
    "v=DKIM1; k=rsa; p=MIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEAyGm4KfaBhFDhZzfkNw7pan+XE+TmIyr03F3/AMU8SXFwgItBU/PikYlddmgf7yhQoqlPrUMEqPZXHfIE8uGg1LtxU2/490wRkuu9ZorEjRkIXSbev1GyAinBQNa5Rln2S+AeBhFDhZzfkNw7panbVJ0HPREiZAJ5TQEX1LjTqB/nArmNaMXaRUCwmYzGY45z8" eW2BJMM7Ftsj3nOPYRbYxLFCzroSSOaMDdcvpCglrFWoF1dXA78ORuvMSL27l8A5+UWRFBQ490wRkuu9ZorEjRNeTlafawRk2B3C/dNcwpoLjz3T1wBHctcLnuC13+nMzzyUtgIVgz/7KaGQv5rnQIDAQAB\;
    Some punctuation needs to be removed to format this record correctly.

    • Remove the quotation mark at the beginning of the record.
    • Remove the space and quotation mark in the middle of the record.
    • Remove the slash and semicolon at the end of the record.

    With those few edits, you’re all set to load your DKIM record into your Liquid Web account.

  2. Log into your Liquid Web account.
  3. In the left navigation menu, click on Domains.
  4. The Domains Dashboard has three tabs along the top. Click on DNS.
  5. Scroll down to Current DNS Zones and click the [+] next to the domain where you’re adding the DKIM record. You’ll see a list of your current DNS records. At the bottom of that list, click on Add a New Record. Now, you can follow the steps you’d normally use to add a DNS record.
  6. The first field in your new record is for the subdomain. In this field, enter the first part of your record:
  7. The second field is the time to live, or TTL. This is how quickly new changes will take effect. You can match this to your other DNS records.
  8. Now, choose TXT from the Type dropdown menu.
  9. The last field is the data field. Here you’ll copy and paste the rest of the record cPanel created for you.
  10. Click the green checkmark to save your DNS record.

Now that your DKIM record has been added, all that is left is to add a TXT policy record.

Your DNS is hosted on the same server as your email

If you are using private nameservers on the same server as your email, cPanel will set up your DKIM records automatically! So, once you follow the steps to auto-generate your DKIM record, they are automatically added to your DNS zone in WHM. Just confirm they are correct in WHM:

  1. Log into WHM.
  2. In the search bar above the left navigation, search for “DNS.” Then, click on Edit DNS Zone.
  3. Click on the domain where you auto-generated the DNS record in cPanel, then click Edit.
  4. Scroll down and check to see that your DKIM records are included. If they are, you’re all set!
  5. If the SPF record isn’t there, simply add a new record by copying and pasting the DKIM record information into a new TXT record.

Now that your DKIM record has been added, all that is left is to add a TXT policy record.

Your DNS is hosted with another company

If you registered your domain at another company and host your DNS there, you log into your account with that company to manage your DNS. Find their DNS record editor and enter your DKIM record according to their specifications.

Now that your DKIM record has been added, all that is left is to add a TXT policy record.

Adding a TXT Policy Record

A policy record is a DNS TXT record that talks more generally about DKIM on your server. It shows your server uses DKIM verification and makes DKIM work more smoothly. A policy record is just one more DNS record. Wherever you added the DKIM DNS record, you’ll also add the policy record.

There are different tags that make up the text of a policy record:

  • t=y; tells other servers your domain is testing DKIM. This means if your DKIM isn’t working properly, other servers are less likely to reject your email.
  • o=~; means that some of your mail is signed by DKIM, but not necessarily all. o=-; means all your mail is signed by DKIM. So, if another server receives a message that isn’t signed, it will be rejected.
  • n=your information here; is a note. It doesn’t affect DKIM, but you can use it to explain more about your specific DKIM. This will show up in error logs if something DKIM verification fails.
  • r=postmaster@mysite.com; is the responsible email address for this domain. Use an email address you can access on your server.

Most likely, your policy record will look like this:

_domainkey IN TXT "t=y; o=~; n=Interim Sending Domain Policy; r=postmaster@mysite.com"

Using t=y; and o=~; will help your email be delivered even if the DKIM signature gets broken in transit from your server to the receiving server. Of course, replace “postmaster@mysite.com” with the responsible email address.

Entering your policy record is the exact same procedure as entering any other DNS record. Wherever you entered your domain-specific DKIM record is also where you should enter your policy record: either in your Liquid Web account interface, in WHM, or in the control panel of your external DNS provider

You’ve successfully created a DKIM record for your domain! You can check to make sure it’s working by sending a test message from a domain email account to check-auth@verifier.port25.com. You don’t have to include a subject or any body text. You’ll receive an automated reply with the status of DKIM, as well as other services you may have.

Where Is My DNS Hosted?

From time to time, you’ll have to make changes to your DNS records. For example, if you change IP addresses, your DNS A records will change. You’ll also change DNS if you want to add SPF records to help email authentication. For these changes to work properly, it’s vital to know where DNS is hosted.

DNS is always hosted at your domain’s authoritative nameservers. Your authoritative nameservers, and therefore your DNS, can be in three places:

  • Liquid Web’s nameservers
    • ns.liquidweb.com
    • ns1.liquidweb.com
    • ns.sourcedns.com
    • ns1.sourcedns.com
  • Your private nameservers on your server or another server you control
    • Ex.: ns.mysite.com
  • Where you registered your domain name
    • Ex.: Enom, GoDaddy, Namecheap, etc.

If you are using Liquid Web’s nameservers, you can update your DNS records in your Liquid Web account interface. If you use private nameservers on your server or another server, you can update DNS records in the control panel for your server (most likely WHM or Plesk, sometimes cPanel for SPF records). If your nameservers are where you registered your domain name, you’ll need to log into your account at that registrar and edit DNS there.

Either way you check your domains authoritative DNS you should always remember, if you don’t update DNS in the right place it wont take effect. This could mean your websites won’t load properly and can cause unnecessary downtime.

Discovering Where DNS Is Hosted – Web

If you aren’t comfortable using your terminal program to look up WHOIS information, use an online WHOIS checking tool.

Discovering Where DNS Is Hosted – CLI

You can easily find out where your DNS records are hosted using your server’s WHOIS entries.

  1. Launch your terminal program. Every operating system (Windows, Mac, and Linux) has a terminal program: use your computer’s search function to look for “terminal,” then open the terminal program you find.
  2. In the terminal window, type:
    whois mysite.com
    and press Enter. Be sure to replace “mysite.com” with your site’s domain.
  3. You’ll start seeing a lot of information about your domain, including where it is registered and the nameservers you’re using.
    Domain Name: LIQUIDWEB.COM
    Registrar: NETWORK SOLUTIONS, LLC.
    Sponsoring Registrar IANA ID: 2
    Whois Server: whois.networksolutions.com
    Referral URL: http://networksolutions.com
    Name Server: NS.LIQUIDWEB.COM
    Name Server: NS1.LIQUIDWEB.COM
    Status: clientTransferProhibited https://icann.org/epp#clientTransferProhibited
    Updated Date: 04-aug-2016
    Creation Date: 05-aug-1997
    Expiration Date: 04-aug-2026
  4. Look specifically at the Name Server listing. In this example, you’ll see liquidweb.com uses Liquid Web’s nameservers. You might also see your own server listed as the nameserver (ns.mysite.com) or a domain registrar listed as the nameserver. This information tells you where you will be editing your DNS records:
    • If you use Liquid Web nameservers: edit your DNS records in your Liquid Web account.
    • If you use private nameservers: edit your DNS by logging into cPanel and searching for “Edit DNS Zone.”
    • If you use a different registrar’s nameservers: edit your DNS records by logging into your account at your registrar.

How to Configure Your DNS for CloudFlare

Getting Started With CloudFlare™

Pre-Flight Check

  • This article assumes that you have already set up CloudFlare and added your domain.
  • We’ll be adding DNS records in Liquid Web’s Manage dashboard. If your site isn’t using Liquid Web’s nameservers, you’ll need to make changes at your registrar or DNS provider.
  • We’ll be using cPanel to set up an .htaccess redirect. If you don’t have access to cPanel, you will need to edit your .htaccess file directly; if you’re using a web server other than Apache (such as Nginx or IIS), you’ll need to set up the redirect manually. You can find tips for doing so in the bonus content section of this article.
Note: If your site’s DNS records are managed by CloudFlare or any other external source, our Heroic Support® team can provide the records you will need to add there to configure CloudFlare, but we will not be able to access your DNS records themselves.

Step #1: Get Your CloudFlare DNS Settings

  • Once your site has been added to CloudFlare via Manage, select Domains from the left menu, click on the CloudFlare tab and click the [+] button next to your domain name to expand the CloudFlare dashboard.
  • Now click on the DNS Settings link near the bottom-right corner to view your settings.

    View DNS Settings in the CloudFlare dashboard

  • The popup window will show you the specific changes you’ll need to make for your site:

    CloudFlare DNS settings popup

    Specifically, you’ll need to:

    • Add an .htaccess redirect to ensure all traffic to your site uses the “www” subdomain.
    • Add a CNAME record for the subdomain “cf-landing.yourdomainname.com”.
    • Change your CNAME record for the “www” subdomain to point to “www.yourdomain.com.cdn.cloudflare.net”.

Step #2: Redirect Traffic to Your ‘www’ Subdomain

If you have access to cPanel, setting up the redirect is a simple process using the method detailed below. If you don’t have access to cPanel, though, you’ll need to set up the redirect manually. You can find tips for doing so in the bonus content section of this article.

  • Log into your site’s cPanel and click on the Redirects icon.

    cPanel redirect

  • You’ll set up the redirect on this page:
    • Set the Type of redirect to “Permanent (301)”.
    • Select your domain name from the http:// dropdown menu.
    • Leave the / field blank.
    • In the Redirects to field, enter the full URL to which you want to direct traffic. As shown below, it must include both the protocol and “www” subdomain. In this case, we want to redirect traffic for “http://example.com” to “http://www.example.com”, so we’ve put “example.com” in the http:// field and “http://www.example.com” in the Redirects to field.

      13cpanelredirect2

  • Once done, click the Add button at the bottom to put the redirect in place and move on to the next step.

Step #3: Add the CloudFlare Landing Page Record

  • In your Manage dashboard, select Domains from the left menu, then click on the DNS tab to see a list of your domains.
  • Now click the [+] to the left of your domain name to display all of its DNS records.

    Manage dashboard domain DNS

  • Click the Add New Record button in the bottom right to add the new record.

    Add DNS record in Manage

  • We want to add a CNAME record for the CloudFlare landing subdomain, so enter “cf-landing” into the NAME field, select “CNAME” for the TYPE field, and set the TTL field to a reasonable value. TTL, or Time To Live, tells DNS servers how frequently to look for changes to the record. The value is listed in seconds, 3600 (one hour) is typically sufficient. Once done, click the green checkmark button to add the record.

    Add a CNAME DNS record for CloudFlare

  • Review the record details in the popup window to make sure they match the values provided by CloudFlare, and click the Confirm button to add the record.

    Confirm the addition of a CloudFlare DNS record

Step #4: Change the Data Field Value for Your ‘www’ Subdomain

  • Locate the entry for your “www” subdomain and click the Edit button to change its value.

    Edit WWW record

  • In the DATA field, change the current value from your domain name to the value provided by CloudFlare. In this case, we’re replacing “example.com” with “www.example.com.cdn.cloudflare.net”. Because this is an existing record, DNS will abide by the record’s current TTL value; lowering it at this point likely will not speed up propagation, but you may want to check that it has a reasonable value.

    Change the value of your WWW record for CloudFlare

    Once you’ve entered the correct value, click the green checkmark button.

  • Finally, review the values presented on the popup window, and then click the Confirm button to add the record.

    Confirm www CNAME change

  • Once CloudFlare sees the DNS changes you’ve made, web traffic to your site will be routed through its servers. Note that it can take up to 24-48 hours for the DNS changes you made to fully propagate across the Internet, but in many cases you will see the changes take effect much more quickly.

Next Step: Configure Visitor Logging

Because CloudFlare acts as a proxy, sitting between your website and the rest of the Internet, your server will, by default, log all visits to your site as having originated from CloudFlare. Fortunately it is a simple matter to configure your web server so that site visitors’ actual IP addresses will be logged. Proceed to Part Three to get started.
 

Bonus: Domain Redirects for Sites Without cPanel

If you don’t have access to cPanel or are using a web server other than Apache, you’ll need to set up the “www” redirect manually. These instructions cover the general steps for popular web servers:

Apache

Apache redirects are accomplished via .htaccess files. The one you’ll need to edit will be located in your web site’s root directory, but you may need to check a box in your FTP client to show hidden files in order to see it. If you don’t already have a file named “.htaccess” in your site’s main directory, you’ll need to create one.

To redirect your non-www domain to www, simply add these lines at the beginning of your .htaccess file:

RewriteEngine on
RewriteCond %{HTTP_HOST} !^www.
RewriteRule ^(.*)$ http://www.%{HTTP_HOST}/$1 [R=301]

IIS

The non-www to www redirect can be made in IIS by adding the following redirect to the site’s web.config file:

<rule name="WWW Redirect" enabled="true" stopProcessing="true">
<match url="(.*)" ignoreCase="true" />
<conditions>
<add input="{HTTP_HOST}" negate="true" pattern="^www.(.+)$" />
</conditions>
<action type="Redirect" url="http://www.{HTTP_HOST}/{R:0}" appendQueryString="true" redirectType="Permanent" />
</rule>

Nginx

Nginx redirects may be configured in the site’s virtual host (.vhost) file or main configuration file, depending on the server version and operating system. Since Nginx is not supported by Liquid Web, we’re assuming that you already know how to edit the virtual host configuration.

To redirect your non-www domain to www, you’ll need to ensure that the primary server is configured to use only the “www” subdomain for its server name.

First, back up the configuration file and then locate the server block for your domain. If both the www and non-www versions of your domain name are listed in the same server block, remove the non-www reference to your site from that server name line. Then create a separate server block for the main, non-www, domain, similar to this one:

server {
listen 80;
server_name yourdomainname.com;
return 301 http://www.yourdomainname.com$request_uri;
}

This will direct all traffic directed at your site’s main domain to the www version of your domain name. Once you’ve finished, restart nginx for the change to take effect.
 

How To Add a Record With the DNS Zone Editor in cPanel

  1. This tutorial assumes you’ve already logged in to cPanel, and are starting on the home screen.

    cpanel-paperlantern-14-dns--01

  2. Now let’s learn how to add an "A record" with the DNS Zone Editor.

    cpanel-paperlantern-14-dns--02

  3. Click the "Simple Zone Editor" icon.

    cpanel-paperlantern-14-dns--03

  4. Select the domain you want to edit.

    cpanel-paperlantern-14-dns--04

  5. Then enter the "A Record", followed by the IP address you want it to point to.

    cpanel-paperlantern-14-dns--05

  6. Click Add a Record.

    cpanel-paperlantern-14-dns--06

  7. That’s it! We’ve successfully added an "A Record" to our domain.

    cpanel-paperlantern-14-dns--07

  8. You can see the new record listed here at the bottom …

    cpanel-paperlantern-14-dns--08

  9. Which is also where you can click to delete the record when it’s no longer needed.

    cpanel-paperlantern-14-dns--09