When you are ready to upload your website, in order for it to display on the Internet the files must be placed in the correct folder. By default, your primary domain document root is public_html. You can change the Directory Index of your site by modifying the .htaccess file.

What is the Document Root?

Your Main Domain

All domain names in your account have a document root. The document root is the folder that stores the files for your website. The document root for your main domain name is the public_html folder.  When you are ready to upload your website, the files will go into the public_html folder.  Once you have uploaded an index page, it will over-ride the default "Hello There!" page that accounts show upon sign-up. 

Addon and Sub Domains

When you add additional domains to your account, it will create a folder in your public_html folder for that domain.  With a subdomain the folder will be called the same name as the subdomain, for example public_html/subdomain.  For an Addon Domain, by default it will create a folder in your public_html folder with the same name as the Addon Domain.  If you would like you can change the document root for your Addon Domain when it is created to a different folder.

What is a Directory Index?

The directory index is the first file the server loads and by default will be the index file within the document root of the domain (the public_html folder if it is your primary domain).  Our servers always load the file called "index" if your domain is typed into the browser, first looking for index.htm, then index.html, and finally index.php. When your account is first created, we also place the default.htm file (the default "Hello There!" page) in your account that will load if no index files are found. If there is no index or default file in your folder, then the website will not load unless the directory index is modified.

Changing the directory index

Some website design applications will name the home page something other than index. For example, the application may name your homepage Welcome.html or Home.html. If your application does this, you will need to modify your site so that the directory index matches the name of your website's first page. You can do this using a .htaccess file.

In the following example we will assume you want your domain to point to Welcome.html when it is visited in a browser. We need to update the .htaccess file so that the server will load Welcome.html first.  Open (or create) the .htaccess file in your domain's document root and add the following line: DirectoryIndex Welcome.html.  Once that is added, when your domain is visited that page will be loaded first.  Please note that our servers are case sensitive when adding the new directory index.

Directory Structure

When uploading files with either an FTP program or a site design program such as Dreamweaver, it is important to keep in mind that any folders you upload to your account will become additional folders in your directory structure. For instance, if you're uploading site files for your main domain name and you are uploading a folder named images, then the path would be public_html/images/ when viewing the folders/files in either FTP or cPanel File Manager. If you want to access that folder from your website, the path would be yourdomainame.com/images. 

If you ever see any broken links or images on your site, one of the first things you'll want to check is where the link or image is pointed to. You can hover over a link with your mouse to see the path it is pointed to. To find out where an image is pointed to right click the broken image and select either View Image Info, Properties, Copy image url or something similar (depending on your browser and version). Once you have the path, double check that the document or image is in the folder your link or image is pointed to.

Did you find this article helpful?

We value your feedback!

Why was this article not helpful? (Check all that apply)
The article is too difficult or too technical to follow.
There is a step or detail missing from the instructions.
The information is incorrect or out-of-date.
It does not resolve the question/problem I have.
How did you find this article?
Please tell us how we can improve our Help Center:
Email Address
Optional, but our team may contact you for more information.
Did you find this article helpful?


2012-09-01 4:20 pm
What about my temporary URL?
8,823 Points
2012-09-04 11:21 am
Hello clives5,

The temp URL and the domain name are pointing to the same place, which is the public_html folder. You would use the same rules above for both the Temp URL and the regular domain names.

Best Regards,
Scott M

Post a Comment

Email Address:
Are you a bot?

Please note: Your name and comment will be displayed, but we will not show your email address.

News / Announcements

Update to SSL Certificates - Certificate Warnings
1969-12-31 11:00 am EST
Hits: 679

Related Questions

Here are a few questions related to this article that our customers have asked:
Would you like to ask a question about this page? If so, click the button below!

Help Center Search

Current Customers

Email: support@WebHostingHub.com Ticket: Submit a Support Ticket
Call: 877-595-4HUB (4482)
757-416-6627 (Intl.)
Chat: Click To Chat Now

Ask the Community

Get help with your questions from our community of like-minded hosting users and Web Hosting Hub Staff.

Not a Customer?

Get web hosting from a company that is here to help.