Knowledgebase

Setting Up a Subdomain for a Separate Application Print

  • dnsnameservers, subdomain, cpanel, ssl, dns, domain, htaccess, troubleshooting
  • 0

A distinct site under your domain.

THE STEPS

  1. cPanel > Domains > Create a subdomain
  2. If DNS is external, add an A record for it there
  3. Confirm it resolves
  4. Run AutoSSL, ticking the subdomain
  5. Install the application in its directory

THE DOCUMENT ROOT

cPanel sets one automatically. If the application expects a different structure, adjust it under Domains.

Modern frameworks frequently expect the web root to point at a subdirectory. Serving the project root exposes configuration files.

WHY A SUBDOMAIN RATHER THAN A SUBDIRECTORY

Separation. Rewrite rules do not conflict, and the application has its own space.

A subdirectory shares the main site's .htaccess and cookies, which can cause genuine problems.

WHY A SUBDIRECTORY RATHER THAN A SUBDOMAIN

Search authority is shared, which suits content that is genuinely part of the same site.

CERTIFICATE COVERAGE

Each subdomain needs it. Run AutoSSL after creating one.

MAIL

A subdomain does not receive mail unless you configure it to. Usually you do not want it to.

REMOVING IT

Remove the subdomain in cPanel and the DNS record if external.


Was this answer helpful?
Back

Are you happy with your experience? Leave us a review on Trustpilot.


Trustpilot