How to protect specific folder or disable directory browsing using htaccess?
Use the following htaccess code to protect a specific folder on your website or disabling directory browsing. This is useful if your folder doesn’t have a default index page and all files within that directory can be easily seen and downloaded by visitors. It is particularly useful if you are selling digital downloads such as zip files in a directory. To avoid that use the following code in the .htaccess file.
# disable directory browsing
Options All -Indexes
Options All -Indexes