84

I have several web site set up on one IIS 6 server distinguished by Host Header.

However, I wish to have one of the sites served by a Linux / Apache server on my network. Do I need to use a reverse proxy add-in for IIS, or is there a simple way to tell IIS to pass on all requests to another server?

Daniel O
  • 1,075
  • 1
  • 8
  • 9

4 Answers4

89

For IIS 7.5, Microsoft provides official modules for this!

In the site settings, you'll get an "URL Rewrite" icon.

  • Open it
  • right click on the "inbound rules list"
  • Select "Add Rule(s)"
  • Choose "Reverse proxy"

In this dialog you can enter the hostname + port to forward to. After adding the rule, opening the edit dialog offers more customizations.

vdboor
  • 3,630
  • 3
  • 30
  • 32
  • 8
    That's nice and all, but the original question specified IIS 6, so I'm confused that an answer specific to IIS 7.5 has been marked as 'accepted'. Was there a solution for IIS 6? – Tim Long Dec 12 '10 at 00:54
  • @Tim: you can use the ISAPI rewrite mentioned below, but other then that, I'm not familiar with IIS6 solutions. – vdboor Dec 14 '10 at 12:28
  • I'm having troubles on my Win10 machine and I can't install this. Are there any limitations for these modules? Is it necessary to run it on a Server OS from MS? thanks – fpdragon Dec 19 '16 at 21:11
  • 1
    Be advised that there are problems reverse proxying POST requests using this method – Casper Leon Nielsen May 04 '17 at 11:17
  • @fpdragon ARR 3.0 URL Rewrite 2.1 installed via the web platform installer worked for me on Win10/IIS10 without issue. – MaxPRafferty Jun 28 '17 at 17:39
  • 2
    @CasperLeonNielsen Could you please point us to some more details about the potential POST issues? – Jens Ehrich Aug 11 '17 at 18:19
  • @CasperLeonNielsen Could you elaborate on potential problems reverse proxying POST requests? – Toothbrush Jan 11 '19 at 14:18
17

I'm using a third-party software for Windows (IIS) for this purpose, which - besides other things like URL rewriting - does this job pretty well: ISAPI Rewrite.

ISAPI Rewrite is a powerful URL manipulation engine based on regular expressions. It acts mostly like Apache's mod_Rewrite, but is designed specifically for Microsoft's Internet Information Server (IIS). ISAPI Rewrite is an ISAPI filter written in pure C/C++ so it is extremely fast. ISAPI_Rewrite gives you the freedom to go beyond the standard URL schemes and develop your own scheme.

Search for "Proxying". Here is the documentation for the RewriteProxy Rule.

There is also a very similar open-source project: Ionic's Isapi Rewrite Filter.

splattne
  • 28,348
  • 19
  • 97
  • 147
1

No, not on IIS 6. Look at using nginx/ubuntu (or even nginx on windows) as a reverse proxy in front of your IIS6 server. We had to use IIS7.5 for reverse proxy features

John Fox
  • 310
  • 4
  • 14
-2

This Microsoft KB article should help answer this request.

Procedures to redirect requests to another Web site or directory:

  1. In IIS Manager, expand the local computer, right-click the Web site or directory you want to redirect, and click Properties.

  2. Click the Home Directory, Virtual Directory, or Directory tab.

  3. Under The content for this source should come from, click A redirection to a URL.

  4. In the Redirect to box, type the URL of the destination directory or Web site.

Peter Ivan
  • 103
  • 5
Nick O'Neil
  • 1,769
  • 11
  • 10