Knowledgebase

Controlling Directory Listings with Index Manager Print

  • cpanel, uploads, wordpress, https, backup, htaccess, errors, guide
  • 0

If a folder has no index file, the server may display a list of everything inside it. Visitors can then browse and download your files directly.

WHY IT MATTERS

An open directory listing exposes backups, uploads, scripts and anything else you assumed was private simply because it was not linked. Automated scanners look for exactly this.

CHANGING THE SETTING

  1. In cPanel open Indexes under Advanced.
  2. Browse to the folder and click Edit beside it.
  3. Choose: No Indexing: recommended. Visitors get a 403 instead of a file list. Default System Setting: uses the server default. Show Filename Only, or Show Filename and Description: display a listing.
  4. Click Save.

Apply No Indexing to your whole public_html unless you have a specific reason to show a listing.

AN ALTERNATIVE

Adding this line to .htaccess achieves the same result:

Options -Indexes

CHECKING

Visit a folder with no index file, such as https://yourdomain.com/wp-content/uploads/ and confirm you get a Forbidden message rather than a list of files.


Was this answer helpful?
Back

Are you happy with your experience? Leave us a review on Trustpilot.


Trustpilot