Directory listing, also known as directory browsing or indexing, is a feature that allows users to view the contents of a directory on a website. While it can be useful in certain cases, it can also pose security risks by exposing sensitive information. In cPanel, you have the ability to disable directory listing to enhance the security of your website. In this article, we will guide you through the steps to disable directory listing in cPanel.
Steps to disable Directory Listing in cPanel
- Log in to your cPanel.
- Click Indexes.
- In Index Manager, you will see a list of directories and files in your website’s root directory. Locate the directory for which you want to disable directory listing and click Edit.
- Select No Indexing and click Save.
Users who directly visit your directory will now see a ‘403 Forbidden’ error.