Creating Subdomains in cPanel

Subdomains are extensions of your main domain that can be used to host separate websites or sections of your site. Common examples include blog.yourdomain.com, shop.yourdomain.com, or members.yourdomain.com. This guide will walk you through creating and managing subdomains in your dotCanada.com cPanel.

What is a Subdomain?

A subdomain appears before your main domain name, like this: subdomain.yourdomain.com. Each subdomain can:

  • Have its own website files and content
  • Run different applications or CMS platforms
  • Have separate statistics and logs
  • Be managed independently of your main domain

Creating a Subdomain in cPanel

  1. Log in to your cPanel account at https://{hostname}.mysecureservers.com:2087
  2. In the search box at the top, type "Subdomains" or navigate to the DOMAINS section
  3. Click on Subdomains
  4. In the "Create a Subdomain" section:
    • Enter the subdomain name you want to create (e.g., "blog" for blog.yourdomain.com)
    • Select the main domain from the dropdown menu (if you have multiple domains)
    • The "Document Root" field will auto-populate with a suggested directory path. You can modify this if needed
  5. Click Create
  6. cPanel will create the subdomain and the corresponding directory
Directory Path Info: The document root is where the files for your subdomain will be stored. By default, cPanel creates a folder with the subdomain name inside your public_html directory (e.g., /public_html/blog/ for blog.yourdomain.com).

Managing Your Subdomain Content

After creating your subdomain, you can add content to it:

  1. In cPanel, go to File Manager
  2. Navigate to the document root directory you specified when creating the subdomain
  3. Upload your website files or install a CMS like WordPress

Installing Applications on Your Subdomain

To install applications like WordPress on your subdomain:

  1. In cPanel, search for "Softaculous" or navigate to the SOFTWARE section
  2. Click on Softaculous Apps Installer
  3. Select the application you want to install (e.g., WordPress)
  4. In the installation form, select your subdomain from the "Choose Domain" dropdown
  5. Complete the rest of the form and click Install

Viewing and Managing Existing Subdomains

To manage your existing subdomains:

  1. Go to the Subdomains section in cPanel
  2. You'll see a list of all your subdomains with these options:
    • Remove: Delete the subdomain (this will not delete the directory or files)
    • Manage Redirection: Set up URL forwarding for the subdomain
    • Document Root: Change where the subdomain's files are stored
    • Stats: View traffic statistics for the subdomain

Subdomain DNS Records

When you create a subdomain in cPanel, the necessary DNS records are automatically created. However, if you're using custom DNS elsewhere, you'll need to create an A record pointing to your hosting server's IP address:

  • Record Type: A
  • Name/Host: Your subdomain name (e.g., "blog")
  • Value/Points to: Your server IP address (found in your welcome email or cPanel dashboard)
  • TTL: 3600 (or default)

SSL Certificates for Subdomains

If you need SSL security for your subdomain (https://subdomain.yourdomain.com):

  1. In cPanel, search for "SSL/TLS" or go to the SECURITY section
  2. Click SSL/TLS Status
  3. Find your subdomain in the list and click Install Certificate
  4. Alternatively, you can use Let's Encrypt to issue a free SSL certificate for your subdomain
Important Notes:
  • Subdomains may take 24-48 hours to become visible due to DNS propagation
  • Each subdomain counts toward your total addon domain limit if your hosting plan has restrictions
  • Deleting a subdomain from cPanel doesn't automatically delete its files - you'll need to remove those separately
  • For security reasons, set up separate databases for applications installed on different subdomains

If you need assistance with creating or managing subdomains, please contact our support team.

Was this answer helpful? 0 Users Found This Useful (0 Votes)