Normally, CloudFlare services are enabled for a given domain name and once activated can also be applied for any other subdomains of it also. Before you use CloudFlare for your desired subdomain, you would have to enable the service for your main domain first. You can find out how to enable CloudFlare for your main domain in a CloudFlare Tutorial.
When you active the main domain in cloudflare, you can easily use subdomain of that domain in Cloudflare. To do this follow these steps:
- At first, Log in/ Sign in to your registered CloufFlare Account
- After that, you will be redirected into the CloudFlare Overview
- From CloudFlare overview, select any of the previously added website (main domain)
- After selecting (clicking on) your main domain, you will be redirected to https://www.cloudflare.com/a/overview/yourmaindomain.com
- Next, Click on DNS tab of the CloudFlare Overview Page. Then you will be redirected to the Cloudflare DNS management page.
- In the DNS management page, type your “Sub-Domain” into the Name Box (of Type from A Name Record, see the below screen shot), type IP address of the “main domain” into the IPv4 Adress Box and then click on “Add Record”
- After that, your sub-domain will be added under your main domain and your sub-domain will be live after 5-10 minutes.
In the above way, you can add a lot of Sub-domains under your added main domain. Hope you have understood all. Further if you have any query, please, do not hesitate to contact with me through putting comments in the comments section.
See Video How to Set Up a CloudFlare Account with Your Main Domain & a Sub-Domain:
If you like, you can bookmark or share it to your friends.