How to create Subdomain and Addon domain on hosting using cPanel
In this post, I will guide you how to create Subdomain and Addon domain for your main domain with the easiest and most accurate way. You do this on your hosting with cPanel supported.
I think that this is a very easy process for almost webmasters. They create or delete subdomains and addon domains frequently. Doing this in just a few simple steps. But there are still some guys don’t know how to do this.
If you’ve already known these processes well, then you don’t need to read to the end of this post. Otherwise, this post may help many other guys in their work.
- What is a Domain Name? Where should you buy?
- Top Web Hosting Reviewed by eCoupon.io latest
- Top 5 Do’s and Don’ts when choosing a Web Hosting provider
How to create Subdomain?
Firstly, login to your hosting account with the information that the provider sent to you via your email. At cPanel dashboard, scroll down to Domains section and choose Subdomains as image below
Then type in your new desired subdomain in “Subdomain” text-box. Choose the domain you want to create its subdomain at “Domain” text-box below. After choosing your domain, you will notice that the Document Root path will be generated automatically for you. By default, it’s located at the same level with your main domain (with folder public_html). But we should change this path to have better security and easier to manage.
There’re 2 cases below
- If you want to create a subdomain for your main domain (the domain belong with cPanel when you register), you should move the subdomain folder to public_html folder. Example: /public_html/subdomain
- Or if you want to create a subdomain for an addon domain, you need to move the subdomain folder to your addon domain public folder. Example: /public_html/addon_domain/subdomain
After finishing fill in all information, click on the “Create” button to start the process and wait for some minutes
How to create Addon domain?
Firstly, login to your hosting account with the information that the provider sent to you via your email. At cPanel dashboard, scroll down to Domains section and choose Addon Domains as image below, it’s beside the Subdomains icon
It’s the same when you create the subdomain, just type in your desired addon domain in “New Domain Name” textbox. Then it will generate to you the new Subdomain and Document Root automatically
By default, if you don’t change anything, your new addon domain Document Root path will be at the same level with your main domain folder (public_html folder). And this may cause you some problems in security and managements. In stead of that, you should try to change the default Document Root to become child folder of public_html. Example: /public_html/addon_domain
Moreover, you can also create your new FTP account for that new addon domain. Just simple tick on the checkbox “Create an FTP account associated with this Addon Domain“, then fill in the FTP username, Password, Password (Again). Finally, press on the “Add Domain” button to finish.
You also need to point your new added Addon domain to your host in order to let it works properly. In order to do so, login to domain management account at your domain registrar and point the DNS to your host.
Below are some simple steps to create Subdomain and Addon domain on hosting using cPanel. Almost guys are doing this easily, and certainly, you can also do that. Just remember to change the default location of Document Root in order to make it more secure and easier to manage.
Good luck to you,