What is www and public_html directory in my folder?


The public_html directory is the folder to place in web-readable files. This means that public_html is the folder where you put all website files which you want to appear when someone types your main domain. Files placed below the public_html folder will not be visible on the web. The www folder is what is called a symlink. This points to the public_html folder and generally is used as a shorthand in CGI scripts for the path. Rather of using the path /home/yourusername/public_html you can use /home/yourusername/www. The www directory is simply a symbolic link to the public_html directory. So anything you place in either directory will be identical when viewed from the other directory on the server. One is usually set up as an alias for the other meaning that it doesn’t matter which of the two you use because they both point to the same folder.


public_html folder


The public_html folder is the webroot for your primary domain name. when someone types your domain name into their browser, whatever is in your public_html directory is what will be shown to them. We can explain this using an example: If you have a default filename like index.html or default.html inside your public_html folder, then when someone calls your domain name it will display that page. If you don’t have any default files in your public_html directory, then a list of files in the public_html folder will be shown. You can create addon domains and subdomains in your account and if you have added an addon domain called myaddon.com then it will use the subfolder similar to /public_html/myaddon.com/or if you are added a subdomain called mysubdomain.com then it will use the subfolder similar to /public_html/mysubdomain.com/
You will get only one cPanel account, in Shared hosting accounts, which is why all add-on domains are subfolders of the public_html folder. If you do not want the additional domains to be subfolders of the public_html, then going with the reseller, VPS or dedicated hosting is a better solution since you can put each domain in its own cPanel to keep it separate from other domains.


How to access the public_html folder?

You can access your public_html folder from your cPanel interface. Please follow the below-given steps to know about how to access your public_html folder from your cPanel account.

1) Log in to your cPanel account.

2) Navigate to Files >> File Manager.

  

3) You can see the public_html folder on your File Manager page.

 

  

 

The public_html folder should always have 0750 permissions. All folders inside the public_html folder should have 0755 permissions. All files inside the public_html folder should have 0644 permissions.

If you need any further assistance, please contact our support department.

 

 

  • 0 Users Found This Useful
Was this answer helpful?

Related Articles

List of Common Available Ports On Cloud And VPS Servers

Inside our Cloud and VPS hosting services we want to make assured our clienteles have the skill...

Cloud Hosting VS. Shared Hosting

Shared hosting is the general hosting solution. But using a shared hosting solution user has to...

How to block IP using .htaccess file?

1) You may block entrance to your website from particular IP addresses using .htaccess file.2)...

How to Delete a cPanel Account From SSH

You can also terminate an account using SSH/command line if wanted using the following script....

How to Delete a cPanel From WHM

Eliminating an existing cPanel account is a very fast and easy process, but be advised this move...