Super User is a question and answer site for computer enthusiasts and power users. Join them; it only takes a minute:

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 need an http server to serve up static content on localhost.

It needs to meet the following conditions:

  • easy to install, minimal configuration, just fire up from a directory and that's it
  • supports OSX
  • small memory footprint
share|improve this question
Doesn't OSX have Apache built-in? – Brad Jul 26 '11 at 18:51
Maybe, I didn't check. But I wouldn't call it lightweight and very easy to configure – Ovesh Jul 26 '11 at 18:52
It can certainly be lightweight. Easy to configure is another matter, but if it is already running, your configuration is done. – Brad Jul 26 '11 at 18:53
fair enough. That was easy. If you want to write up a small answer I'll give you the credit. – Ovesh Jul 26 '11 at 19:10
up vote 2 down vote accepted

Apache is built into OSX an can easily be enabled.

See for some basic instructions.

share|improve this answer
I didn't read it through. All I did was go to "Sharing" in System Preferences, enable "Web Sharing", and I'm using my local ~/Sites as the directory. Pretty simple. – Ovesh Jul 26 '11 at 19:39
It'd be great to provide the instructions here rather than just linking somewhere! But as @Ovesh said, it can be condensed quite easily. – slhck Jul 26 '11 at 21:35

You can use Python to run a simple http server. From the directory that you want to serve, run the following...

python -m SimpleHTTPServer

See this Linux Jornal article for more info.

share|improve this answer
What a great solution. It just works! – Ovesh Jul 27 '11 at 6:52

You can use MAMP.

It comes with Apache, PHP and MySQL, and sets it all up with a few clicks. Note that you should never use MAMP in a production environment; PHP & MySQL settings are optimal for development but there are some security vulnerabilities.

share|improve this answer

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .