To enable index listings for a directory add the following line to the .htaccess file:

Options +Indexes

This directive enables standard indexing, where the index listing shows only the filenames. You can also enable “fancy” indexing, where the index listing shows filenames, their filesizes, and when they were last modified. To do this, add the following line to the .htaccess file:

IndexOptions +FancyIndexing


To disable index listings for a directory add the following line to the .htaccess file:
Options -Indexes

If you wish to stop fancy indexing but keep normal indexing active, open the .htaccess file's IndexOptions line in a text editor and make the following changes:

IndexOptions -FancyIndexing
Was this answer helpful? 0 Users Found This Useful (0 Votes) htaccess rule, htaccess file