Knowledgebase Home / Manage and Change File Permissions with cPanel File Manager
// View Comments //

Manage and Change File Permissions with cPanel File Manager

In this article, you will learn how to manage and change file permissions in cPanel using the cPanel File Manager.

When files and directories are created in cPanel’s File Manager, the default permission are assigned. The default permissions for directories and files in cPanel are 755 and 644, respectively. Most users would never need to change the permissions, but at times when an update/installation fails or due to corrupted files/folders, the files and directories in cPanel can have the incorrect permissions. In this document we will discuss how to fix incorrect permissions.

Default Permissions

public_html - 750
Folders - 755
CGI and Perl scripts - 755
.html .php and other Document Types - 644

Files with lesser permissions than that of the default permission will encounter issues such as request denied, forbidden, etc. when requested by the server. If the permission is higher than that of default permission set, it can allow unauthorized users to access and compromise your site. The contents in your site should always be set to the default permissions.

How we can change the permission via cPanel File Manager.

1. Login to cPanel and click on File Manager

Login into Cpanel Veerotech Hosting

cPanel Main Page

2. Once inside the File Manager, select the file/directory and then click on Permissions to change the current permission. You can also right-click the file/directory and click Change Permissions to edit the permission.

File Manager change Permissions

File Manager change Permissions

Next, you’ll get a popup window on which you can adjust the permissions by checking the box for each permission you want. The window will also display the corresponding numeric value for the permission you’ve set.   

3. Click on Change Permission to confirm the changes.

How to change Permission in VPS.

If you have root access to the server, then executing a single script called “Fixperms” will fix the incorrect permissions. First, download the script to a temporary location and execute it from there.

cd /tmp

wget https://raw.githubusercontent.com/PeachFlame/cPanel-fixperms/master/fixperms.sh

sh ./fixperms.sh -a USER-NAME

This will fix the incorrect permissions in a cPanel user’s root folder.

To fix the incorrect permissions for all the users on the server, execute the command shown below.

cd /tmp

wget https://raw.githubusercontent.com/PeachFlame/cPanel-fixperms/master/fixperms.sh

sh ./fixperms.sh -all

This will set all the users files and directories to the default permission.

Conclusion

Kudos, now you know how to change file permissions in cPanel. Incorrect permissions can cause severe problems for your website. If you find any files or folders with incorrect permissions, it’s recommended to change them to the  default permissions.


If you have any web hosting questions please feel free to reach out to us. We're happy to help.
Shared Hosting | Reseller Hosting | Managed WordPress Hosting | Fully Managed VPS Hosting

Our Guiding Principles

  • Provide consistent, stable, and reliable web hosting services.
  • Ensure rapid ticket response and quick resolutions to issues.
  • Never saturate or over-provision servers to ensure stability and speed for our customers.
  • Use only high-quality enterprise-class hardware to ensure minimal downtime from hardware failures.
  • Provide clear pricing with no hidden fees or gotchas.
Subscribe to comment notifications
Notify of
guest
0 Comments
Inline Feedbacks
View all comments