Vimzaa Knowledgebase
  • Getting Started
  • Virtual Private Servers
    • What is Virtual Private Server
    • Getting Started With Linux
      • An Introduction to the Linux Terminal
      • Basic Linux Navigation and File Management
      • An Introduction to Linux Permissions
      • An Introduction to Linux I/O Redirection
      • Linux Permissions Basics and How to Use Umask on a VPS
    • Connect with SSH
      • How to Add SSH Keys to VPS
      • SSH Essentials: Working with SSH Servers, Clients, and Keys
    • How To Edit the Sudoers File on Ubuntu and CentOS
    • Introduction to Nginx and LEMP on Ubuntu
      • Initial Server Setup with Ubuntu
      • Installing LEMP Stack on Ubuntu 14.04
      • Installing LEMP Stack on Ubuntu 16.04
    • Anti-Spam Best Practices
  • cPanel Hosting
    • Cloudflare
    • cPanel - Advanced
      • How to add and manage cron jobs / scheduled tasks in cPanel
      • How to track DNS using cPanel
      • How to create custom ‘error pages’ in cPanel
      • How to flush your local machines DNS Cache
      • How to use the Google Public DNS for faster DNS lookups
      • How to check if your domain has ‘propagated’ following DNS changes
      • Install Wildcard SSL Certificates using LetsEncrypt with cPanel
      • Correct SPF Records
      • Check processes or users with high iowait (99.99%) from Cloudlinux Logs
      • How to tune MySQL on a cPanel server with MySQLTuner
      • Clear disk space on cPanel Server by removing backups, trash etc
      • Add monitoring script to server for monitoring top, iostat etc
      • Testing your site before ‘go-live’ by editing your hosts file
    • cPanel - Domains
      • How to use the Site Publisher in cPanel
      • Managing addon domains in cPanel
      • What is the difference between addon domains and ‘alias’ domains?
      • Managing subdomains in cPanel
      • Managing domain aliases in cPanel
      • Managing domain redirects using cPanel
      • How to use the Simple Zone Editor in cPanel for managing your DNS Records
      • How to use the Zone Editor within cPanel to manage your DNS records
      • How to redirect all domain ‘alias’ to the main domain using cPanel
      • How to enable Cloudflare on your cPanel account
      • How to check what nameservers a domain is using
      • How to create Custom Nameservers / Vanity Nameservers
      • How do I transfer a domain name to Vimzaa?
    • cPanel - Managing Databases
      • Managing a MySQL Database in cPanel with phpMyAdmin
      • Manage MySQL Database in cPanel
      • Simplified database creation with the cPanel MySQL Wizard
      • Managing MySQL databases remotely using ‘Remote MySQL’ in cPanel
    • cPanel - Managing Email Accounts
      • Managing email accounts with cPanel
      • How to create and manage email forwarders using cPanel
      • Managing email routing with cPanel
      • Change Your E-Mail Account Password
      • Improving mail deliverability (SPF & DKIM)
    • cPanel - Managing Files
    • cPanel - Metrics
    • cPanel - Software and Applications
    • cPanel - Security
    • SiteBuilder Pro
    • Enable or disable PHP modules
    • How can I migrate my cPanels to Vimzaa Website Hosting?
    • SSH Access to cPanel Servers
    • How do I add another domain to my Hosting Account?
    • How do I access WHM (Web Host Manager)?
  • Plesk Hosting
    • An Introduction to Plesk
    • Getting Started with Plesk
      • How to login to Plesk for the first time
      • The Plesk User Interface Explained
      • Understanding Subscriptions in Plesk
      • How to upload content with Plesk
      • How to manage mailboxes / mail accounts with Plesk
      • Managing Web ApplicationsManaging Web Applications
    • Plesk Tutorials
      • A basic getting started guide to creating your first site with Plesk
      • How to manage DNS and nameservers using Plesk
    • Plesk Funtionality - Explained
      • Managing your User Account in Plesk
      • Managing your Web Hosting with Plesk
  • Game Servers
    • Setup Teamspeak 3 Server on Linux
    • Installing SteamCMD for Steam Game Servers
  • SSL Certificates
  • Domains
    • Can I register or transfer my domain to Vimzaa
    • Can I buy a domain name together with a web hosting plan
    • Default nameservers for shared webhosting
Powered by GitBook
On this page
  • Overview
  • Create a New Alias
  • Enable or disable domain alias redirection
  • Remove Aliases
  • Search aliases
  • Domain alias email accounts
  • Addon vs. alias domains
  1. cPanel Hosting
  2. cPanel - Domains

Managing domain aliases in cPanel

PreviousManaging subdomains in cPanelNextManaging domain redirects using cPanel

Last updated 6 years ago

Domain aliases make your website available from another domain name. For example, you can make www.example.net and www.example.org show content from www.example.com

Location Under cPanel
cPanel > Home > Domains > Aliases

Overview

Domain aliases are domains that you own, but which do not contain any content. Instead, they point to the contents of another domain or subdomain on your account. This is useful, for example, to hold a domain that you will later sell, or to redirect traffic to another domain.

Important:

Unless your hosting provider enables the Allow Remote Domains option in the interface (WHM >> Home >> Server Configuration >> Tweak Settings), you must perform the following actions before you attempt to create a domain alias:

  • You must register the domain name with a valid registrar.

  • You must point the domain to your account’s nameservers.

Create a New Alias

To add a domain alias, enter the domain name in the text box and click Add Domain.

To open the alias domain’s home directory with the interface (cPanel >> Home >> Files >> File Manager), click the link that corresponds to that alias under the Domain Root column of the Remove Aliases table.

When you create an addon domain, parked domain, subdomain, or main domain, the system will attempt to automatically secure that domain with the best-available existing certificate. If no certificate exists, the system will generate a self-signed certificate to secure the new domain.

If is enabled for the account that owns the new domain, the system will add a request for an AutoSSL certificate to secure the new domain and install it when available.

Note:

You can create email accounts for domain aliases. For more information, read the section below.

Enable or disable domain alias redirection

To enable or disable redirection of a domain alias, perform the following steps:

  1. Click Manage Redirection for the domain alias that you wish to manage.

  2. To redirect the domain, enter the link to which you wish to redirect the domain alias in the text box.

  3. Click Save. To disable the redirection, click Disable Redirection.

Remove Aliases

Notes:

  • We strongly recommend that you create a full account backup before you perform this action.

  • This action only removes the domain alias, its vhost entries, and its DNS entries. The system retains the alias’s directory contents.

To remove an existing domain alias, perform the following steps:

  1. Click Remove for the alias that you wish to remove.

  2. Click Yes to confirm that you wish to remove the domain alias. To retain the domain alias, click No.

Search aliases

To search through the list of domain aliases, enter the search criteria in the Search text box and click Go. Results that match your search criteria will populate the table.

Domain alias email accounts

  • To move one email account under a domain, run the following command:

    mv /home/old_account/mail/domain_name/email_account /home/new_account/mail/domain_name/

    When you run this command, the system creates the /home/new_account/mail/domain_name/ directory.

  • To move all of the email accounts under a domain, run the following command:

    mv /home/old_account/mail/domain_name /home/new_account/mail

  • After you move the files, change the new account’s ownership with the following command:

    chown -R new_account:new_account /home/new_account/mail/domain_name

    Note:

    Make certain that you verify ownership of the email account after you move it.

  • If you add the domain again, to the same account as the primary domain, an addon domain, or an alias, the email accounts reappear in the interface.

  • If you change the account’s primary domain name to the un-aliased domain name, the email accounts reappear in the interface.

  • If you move the domain to a different account, you must add the email accounts manually and move the contents of the email accounts manually.

    Note:

    The email accounts must follow the same name and domain formats that they previously followed.

Addon vs. alias domains

Characteristic

Addon domains

Alias domains

The main domain appears in the address bar.

Yes

No

The domain uses the following Apache directive:

VirtualHost

ServerAlias

The domain uses separate logs.

Yes

No

The domain uses separate stats.

Yes

No

The system treats the domain as a subdomain (other than the URL).

Yes

No

This type of domain is ideal for multiple domains that share the same address.

No

Yes

To add new email accounts, use cPanel’s interface (cPanel >> Home >> Email >> Email Accounts), or run the /scripts/addpop script from the command line.

If you remove the domain alias, its email accounts will no longer appear in the interface (cPanel >> Home >> Email >> Email Accounts). However, the email accounts’ contents still exist in the mail folder of the user’s home/username/mail/ directory.

You or your hosting provider can perform this action in WHM’s interface (WHM >> Home >> Account Functions >> Modify an Account).

When you perform this action, the former primary domain name’s mailboxes will not appear in the interface (cPanel >> Home >> Email >> Email Accounts). However, the files will still exist.

Tweak Settings
File Manager
AutoSSL
Alias domain email accounts
Email Accounts
Email Accounts
Modify an Account
Email Accounts