I just upgraded my development computer to Mac OS 10.7.3 (Lion) from Mac OS 10.5.8 (Leopard), which required a complete disk erasure. For several years I've used MAMP to run a development server on the machine, along with minor changes to /et/hosts and httpd.conf in order to allow for virtual hosts. Instead of re-installing MAMP, I decided to install MySQL and configure Lion's native Apache and PHP software for my development needs, following the instructions I found here.

Everything worked fine until I tried to make some customizations to emulate the development environment to which I'm accustomed. In particular, I need:

  • Apache to execute any custom .htaccess directives on a site-by-site basis
  • To enable virtual hosts so that I can access my development sites at domains that I define
  • To keep my Sites directory in /Users/username/Dropbox/ instead of in /Users/username/ for automated synching

I'm no Apache wizard, and every time I enable some option to get one of the above working, it causes 403 Forbidden errors when accessing any site in the user directory. I've read dozens of threads here on Superuser and other sites, and tried at least a hundred configurations of httpd.conf, extra/httpd-userdir.conf, extra/httpd-vhosts.conf, and users/username.conf, but none of them seem to help. I've also watched the error and access logs, but I'm not sure how to interpret the results.

This is way over my head, and I'd appreciate any help troubleshooting this. I'm not sure what other information might be helpful. If anyone can point me to a simple step-by-step guide that shows how to configure Apache on OS 10.7 for virtual hosts, .htaccess, and designating a different Sites directory, that would be even better.

Edit: Here's a sample error I get when I change the directory in users/username.conf to /Users/username/Dropbox/Sites/, without making any changes related to .htaccess or virtual hosts:

From access_log: - - [17/Apr/2012:16:45:11 -0400] "GET /~john HTTP/1.1" 403 207

From error_log:

[Tue Apr 17 16:45:11 2012] [error] [client] client denied by server configuration: /Users/john/Sites

1 Answer 1


You should be seeing something in apache's error.log for every 4xx and 5xx error served to browser. Once you share one line we might be able to help better.

Correct way to sync up config/content directories with *BOX is either here: http://hints.macworld.com/article.php?story=20090929052128498 or there: http://en.wikipedia.org/wiki/Comparison_of_Subversion_clients

  • Thank you. I've tried several different configurations and get different specifics in the log for each. I wanted to start at square one and find out the best way to configure OS 10.7's Apache for local web development, rather than report errors generated by silly configurations. I'll edit my post above with a sample error. Apr 17, 2012 at 20:38
  • At first brush the "Sync to Dropbox from anywhere" seemed like exactly what I was doing with MAMP, but the implementation is actually different in an important way. When I followed those instructions, the 403 errors I got from symlinking to my Sites directory in Dropbox disappeared. After that I enabled vhosts via the include on line 470 of httpd.conf, and configured both user.conf and httpd-vhosts.conf to point to /User/username/Sites/, and everything is working now! Time to import my databases. THANK YOU! Apr 17, 2012 at 22:22

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

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