Server Fault is a question and answer site for system and network administrators. 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

So lately I heard about people running apache and nginx together, nginx for static content and apache for dynamic. Can the same be done with lighttpd and apache?

share|improve this question
up vote 1 down vote accepted

Absolutely. lighttpd can act as a proxy to a different web server for content that it doesn't handle locally.

A simple configuration would look like this - say you want lighttpd to send every request in /webapp/ to a different service:

$HTTP["url"] =~ "^/webapp" {
    proxy.server = ( "" =>
        ( ( 
            "host" => "",
            "port" => 8000
        ) )

That configuration would send traffic to (localhost - change that if it's running on a different system) on port 8000 - adjust that configuration to fit your needs. Keep in mind that if the services are running on the same system, you'll need to make sure to move Apache off of listening on 80, which is its default.

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.