Search Our Database
How to change file/folder permissions on cPanel
Introduction
This guide explains how to change file and directory permissions in cPanel using the File Manager. Adjusting permissions is essential for controlling access and ensuring security on your website. Follow these steps whenever you need to modify who can read, write, or execute files and directories on your web server. This process is applicable for cPanel users managing their website files directly through the File Manager interface.
Steps to Change File and Directory Permissions in cPanel
Step 1: Logging into cPanel
- Log in to your cPanel account using the username and password provided by your web hosting provider.
Step 2: Accessing the File Manager
- In the cPanel dashboard, click on File Manager under the Files section.
- Navigate to the directory where the target file or folder is located.
Step 3a: Changing File Permissions
- In the left panel, browse to the subdirectory containing the file whose permissions you want to change.
- In the right panel, select the file you wish to modify.
- Click on the Permissions button in the top menu to open the permissions settings.
Step 3b: Changing Directory Permissions
- In the left panel, browse to the parent directory containing the folder whose permissions you want to change.
- In the right panel, select the directory you wish to modify.
- Click on the Permissions button in the top menu to open the permissions settings.
Step 4: Modifying Permissions
- In the Change Permissions window, adjust the permissions by selecting the desired checkboxes for Read, Write, and Execute for User, Group, and World.
- Alternatively, you can manually enter the permission values using the numeric matrix:
Digit | Permission | Description |
---|---|---|
0 | — | No permissions |
1 | –x | Execute only |
2 | -w- | Write only |
3 | -wx | Write and execute |
4 | r– | Read only |
5 | r-x | Read and execute |
6 | rw- | Read and write |
7 | rwx | Read, write, and execute |
- Click Change Permissions to save your changes.
Conclusion
By using the File Manager in cPanel, you can easily adjust file and directory permissions to control access on your server. Regularly reviewing and updating these permissions helps maintain security and ensures that only authorized users can modify or execute files and directories. Use the numeric matrix to understand and set permissions accurately based on your requirements.
Article posted on 11 January 2019 by ips1