When loading localhost the page located in any folder should load.

Standard server config description file

When you replace the folder in DocumentRoot with your browser, it gives an access error:

Forbidden
You do not have permission to access / on this server.

Permissions of folders and html file changed to 777, 775, 770, 644, but the error did not disappear. All server actions were run via sudo. Replacing the path to any of your folders in the /etc/apache2/www/html section works well.

What access rights do I need to put my own directory so that when the localhost is loaded, the server would issue my page?

  • Apache is usually run as www-data, and www-data should have access to your directory. the easiest thing is to add www-data to your user’s group - Roma Rush
  • text information is logical and correct in the form of text, and not as a picture. - aleksandr barakin pm

1 answer 1

When replacing a folder in DocumentRoot with your browser

as I understand it, implies the directory /test/www/html . if this directory really exists, then it probably lacks an index file. for example, index.html .