Skip to content

How to Setup Reverse Proxy on IIS with URL-Rewrite

Reverse proxy setup IIS. How to Set Up Reverse Proxy Using IIS with URL Rewrite. Configure IIS as a reverse proxy. Reverse proxy in IIS. How to Setup Reverse Proxy on IIS with URL-Rewrite

Category
Windows
Covers
IIS, Proxy
Versions & support
About Windows →
On this page

Most of the system administrator is aware of the reverse proxy. It is a type of proxy server which fetches the resources from one or more computers on clients requests and send back to the client. In simple terms, it works as an intermediate server, which listens to clients query. Then requests to server bases of clients query and returns results to client sent by the server. This tutorial will help you to setup reverse proxy using IIS with URL rewrite and application request routing extension.

We can configure reverse proxy in IIS using URL Rewrite module. This is similar to the mod_rewrite module in Apache. Before starting work make sure you have installed and enabled URL Rewrite module in IIS server.

What is URL Rewrite Module?

URL Rewrite Module is officially provided by IIS development tool to extend the functionality of IIS web server. It provides additional functionality to rewrite application URL. This helps to make clean and SEO friendly URLs.

You can visit below URL and download and install URL rewrite IIS extension:

You also need Application Request Routing extension to install on your system. Visit the following URL to download the extension and install on your system.

For more details, visit our other article here.

Set Up Reverse Proxy Using IIS

Let’s start with the configuration of the reverse proxy. For this tutorial, I have created a dummy web application running on port 3000 using node.js. You can see the below screenshot of the web application.

Reverse proxy using IIS 1

Now, open the IIS by typing “inetmgr” in run window. Select your website under sites in left side section. Now select “URL Rewrite” option.

Reverse proxy using IIS 2

Now click on “Add Rule(s)…” in actions section on the right side. See below screenshot for this link.

Reverse proxy using IIS 3

Now select Reverse Proxy under inbound and outbound section.

Reverse proxy using IIS 4

The above option will open a window, Add the server name or IP address with port under inbound rules input box. This is the URL from where reverse proxy will server data on clients request.

Reverse proxy using IIS 5

At this point, the reverse proxy setup has been done. Now access web site configured with IIS. You will see the backend application is accessible here. This is the reverse proxy in working.

Reverse proxy using IIS 6

This is the reverse proxy in working.

Rahul

Rahul Kumar is the founder and chief editor of TecAdmin.net. A Red Hat Certified Engineer (RHCE), he has worked in IT since 2009, with hands-on experience in Linux system administration, DevOps, web hosting, cloud platforms and automation. He started TecAdmin in 2013 to share practical, step-by-step guides, and leads its editorial work with one aim: making technical learning clear and useful for sysadmins, developers and beginners alike.

4 Comments

  1. Hi Maneesh
    Did you find any solution to the above? I also have similar requirement. If you have a solution can please share it with me.
    I want to do something similar on IIS. Following is for NGINX
    location /proxy/ {
    proxy_pass https://destinationserver:8089/;
    proxy_ssl_session_reuse off;
    }

  2. Hi,
    I have this proxy configuation for my website. How do I go about setting this up in IIS?
    const proxyConfig = [
    {
    context: ‘/web/api/webclient/**’,
    target: ‘https://xx.xxx.xxx.x6’,
    changeOrigin: true,
    secure: false
    },
    {
    context: ‘/rest/**’,
    target: ‘https://xx.xxx.xx.x9’,
    changeOrigin: true,
    secure: false
    },
    {
    context: ‘/api/**’,
    target: ‘http://xx.xxx.xxx.xx7’,
    changeOrigin: true,
    secure: false
    }
    ];

Leave a Reply

Your email address will not be published. Required fields are marked *


Back to top