Occasionally, you may want the content to be in a different folder or directory than the default, or you may already have the content uploaded to a certain folder on your account. In that scenario, you would enter the relevant folder in your domain's Document Root column.
Please be aware that you cannot use certain folders or directories as the document root directory for your addon domain(s). These folders and directories are listed below;
- The account’s Home directory itself (cannot/)
- Directories outside of the account’s home directory (./ and ../)
- .cpanel
- .trash
- etc
- ssl
- tmp
- logs
- .cphorde
- spamassassin
- .htpasswds
- var
- cgi-bin
- ssh
- perl5
The steps in changing the folder or directory of an addon domain in cPanel are explained below:
STEP 1: Log in to cPanel.
STEP 2: In the Domains section, click on Domains.
STEP 3: Locate the Document Root of the Domain Directory you want to change and click ‘Manage’.
STEP 4: In the field, input the New Directory where you want the files for the domain to exist.
STEP 5: Click on ‘Update’.