Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I'm trying to run a python cgi script on my Mac's web server. Everytime I visit the file @ localhost/ I get a 403 forbidden error.

I'm looking in my Apache's error log, and it says:

[Mon Jun 11 09:52:42 2012] [error] [client ::1] Options ExecCGI is off in this directory: /Users/<username>/Sites/

I've changed my httpd.conf file so that my document root is /Users//Sites

In my user's .conf file, I have the following:

<Directory "/Users/<username>/Sites/">
  Options All
  AllowOverride All
  Order allow,deny
  Allow from all
  AddHandler cgi-script .py

Why is it telling me ExecCGI is off, when I've allowed all options in my user's .conf file?

share|improve this question
Are you sure it is fully contained in that directory and does not reference elements outside that directory? – mdpc Jun 11 '12 at 18:08
yep! The only thing it does is print out 'hello world' – jessh Jun 11 '12 at 18:43

Do you use mac's built-in apache2, or package like XAMPP? I found XAMPP doesn't use user.conf, one have to edit /Applications/XAMPP/etc/httpd.conf.

Another things is the change of user.conf take effect AFTER apache restart.

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

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