How do I set a custom directory index?
By default, our web servers will look for the index.html file in order to know what to display when any given directory is accessed, such as public_html.
You can change which index file is looked-for if you don’t wish to use – or can’t use – the default index.html file. Rules are added within the root .htaccess file to make this work.
To make this easier you can use the 20i tool to set the default directory index:
- Head to Manage Hosting and select the package you wish to update the default directory index for.
- Select the Directory Indexing icon.
- Various common index files are pre-filled. You may wish to add your own or simply select Enable Directory Indexing – we’ll then generate the .htaccess rule and add it to the correct location in your site files to set the desired behavior.