500 Internal Error and showing directory only

The setting works most of the time, but not always, depending on the website.

Some software, like Laravel, override the server settings for displaying error. In that case, you need to enable debug mode in the software, or check the logs it produces.

Fortunately, you found the logs already.

I take it you just uploaded the vendor folder from your own computer to your site? Usually this is good enough, but it seems that Laravel specifically wants the development packages to be removed from your site.

To do this, you can run the following command in your project root on your own computer:

composer install --no-dev --optimize-autoloader

This will make the vendor folder production ready by removing the development software and generating an optimized autoloader (which may provide a slight performance boost).

Then you should delete the currently uploaded vendor folder from your site, and replace it with the one you just created. And I think you’ll also want to replace the bootstrap/cache/ folder, because it contains references to which Laravel providers you have installed.