Knowledge Base
MilesWeb / DirectAdmin, How-Tos

How to Enable/Disable Directory Listing with .htaccess via DirectAdmin?

Approx. read time : 3 min

Watch this video for a step by step process on How to Enable/Disable Directory Listing with .htaccess via DirectAdmin

To enable or disable the directory listing, you can edit the .htaccess file via DirectAdmin. All you have to do is add a specific directive to imply the configuration.

To Enable Directory Listing with .htaccess

1. Log in to your DirectAdmin account.

2. Create or edit the .htaccess file using the File Manager tool.

Here’s an article that you can refer: How to Create/Edit .htaccess File via DirectAdmin?

3. You will have to enter this directive at the start of the file.

4. Once you do that, click SAVE.

The next time you browse for the directory listing, it will display the index.

To Disable Directory Listing with .htaccess

1. Create or edit the .htaccess file using the File Manager tool.

2. You will have to enter this directive at the start of the file.

3. Once you do that, click SAVE.

The next time you browse for the directory listing, it will display the 403 HTTP Forbidden Access error.

That is how you can configure the .htaccess file via DirectAdmin to enable/disable directory listing.

Prasad is a business grad specialized in Marketing. He has garnered experience as a technical content writer and a digital marketer that he brings out in his work. He likes reading classics and travel in his free time.
Need help? We’re always here for you.