Reverse Proxying

This is basically easier than standard proxying, as the proxy administrator has some knowledge of the content to be proxied and can at least set up defaults that work well with them.

To set up a reverse proxy for at path / on your server, you need firstly the directives for mod_proxy:

ProxyPass	/
ProxyPassReverse	/

Now, to complete the proxying, you need to ensure that links in the pages at resolve correctly relative to the proxy. The AccessibilityURLMap directive does this. There are usually two cases to deal with:

  1. URLs of the form /path/to/ need to be rewritten to the proxy's address space; in this example to / This is dealt with by
    AccessibilityURLMap	/	/
    to rewrite URLs starting with a slash.
  2. URLs of the form need to be rewritten to the proxy's address space:
    AccessibilityURLMap	/

If you are reverse-proxying other servers - eg to provide external access to an intranet in private address space - you can of course add similar directives for the other servers proxied.


A tutorial on reverse proxying with Apache (by the author of mod_accessibility) is now available at ApacheWeek. It is based on the more limited mod_proxy_html, but the details are basically identical.

Reverse Proxy Demonstrator

We have mod_accessibility running at where it is serving as reverse proxy for selected sites. Sites may be added or removed by request. At the time of writing, a couple of useful sites are available: