403 Forbidden when you open a domain?

What does it mean when you visit your site and get a 403 forbidden error?

Forbidden

You don't have permission to access / on this server.

Additionally, a 403 Forbidden error was encountered while trying to use an ErrorDocument to handle the request.

This primarily means that you don't have index.html, index.htm, index.php, home.html, home.htm, home.php, default.php and default.php. There are a few more variations, but it all boils down to this.

If you get this as soon as you open your domain "vassajt.rs", it means that you don't have one of these files in the public_html folder, which is the main folder for your site. 

This error can also appear if you have, for example, a folder called "documents" and you try to visit vassajt.rs/dokumenti/ and you will get the same error.

This is for security reasons to prevent directory listing if the index file is accidentally missing.

If you still want the files to be listed in the folder, create an .htaccess file (with a dot, meaning the dot htaccess) and set the following:

Options +Indexes

After which you will enable files and folders to be listed when that folder is visited.

Scroll to Top