I'm on Mac OS X and having problem in setting Apache to function properly. When I access localhost it keeps showing 403 forbidden You don't have permission to access this page error. Though I have set Apache to gain access permission on Document Root (AFAK by googling). This is my setting in httpd.conf:

DocumentRoot "/Library/WebServer/Documents"
<Directory />
    Options FollowSymLinks
    AllowOverride None
    Order deny,allow
    Deny from all

<Directory "/Library/WebServer/Documents">

Options All
AllowOverride All

Order allow,deny
Allow from all

Is there something I misunderstood here?


You should check file permissions for the /Library/WebServer/Documents folder. The www user should have at least read and execute permissions on the folders and read permissions on the files. Repair privileges if needed.

My settings (OS X 10.8, working webserver) are:

$ ls -la /Library/WebServer/Documents/
total 72
drwxr-xr-x  5 root  wheel    170 10 Dic 04:03 .
drwxr-xr-x  5 root  wheel    170 10 Dic 04:03 ..
-rw-r--r--  1 root  wheel   3726 10 Dic 04:03 PoweredByMacOSX.gif
-rw-r--r--  1 root  wheel  31958 10 Dic 04:03 PoweredByMacOSXLarge.gif
-rw-r--r--  1 root  wheel     44 12 Mar 17:48 index.html.en

Don't forget to check Apache logs into /var/log/apache2/ (you can read them using the built-in Console application).

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.