In this guide, we will see how to add a sub-domain.
What is a subdomain?
This is the part of the URL of a site that precedes the domain name.
A sub-domain has the form subdomain.your-domain.tld.
www.votre-domaine.tld is a sub-domain
demo.your-domain.tld is also a sub-domain
store.your-domain.tld is also called subdomain
Create a sub-domain
The first thing to do is to go to your client interface which you can find the link to on our showcase site. Once there, click on Plesk > My Plesk (Manage my subscription) > menu Websites & Domains > Add subdomain.
Enter the name of the subdomain. You will notice here that the system adds the root folder of the subdomain as it goes along.
You can leave the document root value as default.
- It is not possible to put special characters or empty spaces in the name and directory of the subdomain
- It is possible to put numbers in the name and directory of the subdomain
- It is not recommended to use capital letters in the name and directory of the subdomain
Or you can put the name of a directory of your choice. If this directory does not exist, the system will create it automatically.
It is possible to put the root folder of the document under the httpdocs.
In our example, we chose to put the root under a folder called subdomain where we will gather all the subdomains in it.
Click on OK to add the subdomain.
The subdomain will use the same FTP account of the main domain.
You will see in the Filesa new directory is added. The image below shows the case where you let the system choose the root folder of the subdomain by itself.
In our case, the root folder displayed will be subdomain/demo.
The creation of our sub-domain is in place, we now need to set the DNS pointer so that it is accessible on the Internet. For this it is necessary to get the IP of the server that hosts your subdomain.
You just have to publish the content on the concerned folder by FTP.