What does the error mean?
Apache is the program that serves websites. When someone visits a folder on your site, for example yourdomain.com/, Apache looks for a starter page inside it. This page is usually called index.html or index.php. That name list is called the DirectoryIndex.
If none of those files exist, Apache has nothing to show. If listing the folder is also not allowed, it shows an error. In the log you will see a line like this:
No matching DirectoryIndex (index.html,index.php) found, and server-generated directory index forbidden by Options directive
Visitors see 403 Forbidden.
Common causes
- You uploaded your site to the wrong folder.
- The home page file is named wrongly, for example
Index.htmlwith a capital I. Linux cares about capital letters. - The file is inside another folder, so it is not at the top level.
- The upload did not finish.
- An old setting in
.htaccesschanged the list of home page names.
Steps to fix
- Log in to cPanel and open File Manager.
- Go to
public_html. This is the folder for your main site. Addon domains may use their own folder. - Look for
index.html,index.phpor similar. - If the file is missing, upload it or move it to this folder.
- If the name is wrong, right-click the file and click Rename. Use lowercase, like
index.php. - Reload your website with a hard refresh (Ctrl and F5).
If the file has another name
Say your home page is home.html. You can tell Apache to look for it.
- In File Manager, click Settings and tick Show Hidden Files.
- Open
.htaccessinpublic_html. Take a copy of it first. - Add this line.
It tells Apache which names to try, in order.DirectoryIndex home.html index.html index.php - Click Save Changes.
Options +Indexes. But this lets anyone see your files, so it is usually a bad idea.Still stuck?
Check folder permissions. Folders should usually be 755 and files 644. If it still fails, open a ticket at https://secure.hostvento.com/submitticket.php.
Quick recap
- Apache needs a home page file like
index.htmlin the folder. - Check the folder, spelling and capital letters.
- Add a
DirectoryIndexline if your file has another name. - Avoid turning on folder listings.