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

It seems to be universally considered good practise to run Nginx as a reverse proxy in front of Apache for serving PHP.

Is this still the case when using a CDN to serve all static assets (images/css/js)?

Obviously serving static files fast is one of the main advantages of having Nginx in front but is it still worth running it with only dynamic requests for it's advantage as a buffer for slow clients?



share|improve this question

In case your project/scripts do not strictly depend on specific or third-party Apache modules it worth to try Nginx/PHP-FPM/APC cache/Memcached bundle to serve dynamic content. It definitely decrease memory usage footprint and allows to handle more requests ceteris paribus.

For high number of popular CMS you can easily find Nginx configuration examples, first place to check is official Nginx site Configuration section.

Further one can consider usage of fastcgi_cache directives from native HttpFcgiModule.

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.