The Directory Listing – which displays the contents of a directory – is served when a particular path is a directory and does not contain an index file.
You can enable or disable the feature from the "Advanced" page in the Project Settings.
When enabled, the Directory Listing will be displayed. When disabled, a "Not Found" error will be displayed with status code
To prevent the Directory Listing from being displayed for a specific directory, add an index file whose filename matches the pattern
.css), such as
index.html, which will then be displayed instead of the Directory Listing when accessing that path.
Use the "Source" tab on the Deployment View to check the source and output of your Deployment's Build if the file you're looking for is not being displayed.
Instead of displaying a specific file for a certain path in place of the Directory Listing, you can also customize the 404 error.
- If the Directory Listing is being displayed on the
/path of your Deployment instead of your application, Vercel likely wasn't able to run a Build Command (defined in the Project Settings). Check out our Build Step documentation for more details.
- If you have tried everything above, please either leave feedback below about information that might be missing or contact our Support Team.