Error 403 - Forbidden with symbolic link

I'm deploying Laravel app in shared hosting.

I've deleted the orginal public_html folder and created symbolic link

ln -s app/public public_html

The symbolic link is success.

But I'm getting Error 403 - Forbidden when accessing the app url.


Solution 1:

If you do not have access to your web server configuration, you can override the configuration to permit symbolic links to be read. In the root directory of your web server, add the line below to the .htaccess file. Create the .htaccess file if it does not exist.

Options FollowSymLinks

This will only work if your main configuration permits the use of .htaccess config files.