Adding Domains & Subdomains

From DreamHost
(Redirected from Hostname)
Jump to: navigation, search


There is no limit to how many domains/subdomains you are able to add to your DreamHost account with shared, VPS, or Dedicated hosting. This article explains how to add the domains to your panel.

Dh-kb-note-icon.fw.png Note: This article does not apply to DreamPress as you are only able to add one domain per service with that plan. You can read more about it here:

FAQs for adding domains and subdomains

How do I add a new domain or subdomain to my account?

To add a new domain or subdomain, log into the panel and follow these instructions:

  1. Go to the (Panel > 'Domains' > 'Manage Domains') page.
    The Manage Domains page opens:
    01 Adding Domain Subdomain.fw.png
  2. Click the Add Hosting to a Domain / Sub-Domain button.
    The 'Manage Domains' page appears with several options to enable.
    01 Add a domain.png
  3. Domain name
    The first section is where you enter your domain and how it appears:
    • Domain to host: enter the name of the domain or subdomain you wish to add.
    • Do you want the www in your URL?: You have three options.
    Leave it alone: The www and non-www version of your site both function.
    Add WWW: This forces www to be added to your domain so when it's visited, it always appears as
    Remove WWW: This forces www to be removed so your domain always appears as
    02 Move Domain to VPS.fw.png
  4. Users, Files, and Paths
    This section allows you to choose your username and the directory where the site is installed.
    • Run this domain under the user: Select a user who owns the files for this domain (you can also create a new user here. If you create a new use you can also assign it to a specific server).
    • Web directory: This is the directory on the server where your site files are located. Most often there is no need to adjust this.
    • Logs directory: This is just to let you know where you can find your site's logs on the server.
    03 Add a domain.png
  5. Web Options
    This section allows you to choose a PHP version to run your site as well as security and optimization options.
    • PHP mode: Click the dropdown menu to choose which version of PHP you wish the site to run under.
    • Automatically upgrade PHP: Check this box to have DreamHost automatically upgrade the version of PHP when available.
    • Extra Web Security?: It's recommended to keep this enabled as it provides further security to your site.
    • PHP XCache Support: This is only available on a VPS and helps to optimize PHP.
    • Passenger (Ruby/Python apps only): Enable if you are running a Python or Ruby on Rails website.
    04 Add a domain.png
  6. CloudFlare Services and Google Services
    This section allows you to enable different CloudFlare and Google services to your domain.
  7. Click the blue Fully host this domain button to save your changes.

For information on how to allow somebody else to manage this new domain or subdomain, visit the following article:

Dh-kb-note-icon.fw.png Note: If you get the following error message:
You can't add that domain: you must add the parent domain to your account before adding a subdomain to it.

it means that the second-level domain is not yet in the system. A subdomain can only be created if its second-level domain is created first ( – even if you don't plan on hosting the second-level domain here at DreamHost.

Do I have to create a new directory if I add a domain?

No, you do not.

A new directory automatically appears (in the name of your domain) in your users directory within fifteen minutes of adding the domain. You don't need to create a new directory yourself.

When somebody visits your website, the configuration files for the DreamHost web server tell the visitor to go to the new directory. When you add a new domain and specify its directory, the panel adds the necessary lines to the necessary config files on the web server. There is no need to for any other configuration other than adding the domain in your panel.

How much is it for an extra domain?

All hosting plans at DreamHost (excluding DreamPress) allow an unlimited number of domains and subdomains.

If you want to host an entirely new domain, you can register it on the (Panel > 'Domains' > 'Registrations') page or through any other domain registrar (although, remember that registration costs may vary).

Does an extra domain have to point to the same place as the original domain?

No, but it can if you'd like it to.

It can point to your existing site, or it can point to an entirely different directory. When adding the domain in your panel, you get to decide where it points.

Does an extra domain get its own storage space, login, email aliases, and so on?

Your extra domain gets its own email addresses.

You can also use the same username as your main domain, or you can create a new username. All web files for the domain are stored under the user you assign to it. But, please note that the amount of space allotted depends on your hosting plan. For example, when you purchase a VPS plan you must choose how much disk space you’d like the user to have.

You can view more information about VPS plans here: