In a few steps this post will show how to use HTTP Redirect in IIS to specify rules that can redirect requests to another file path or website.
- Windows operating system
- Internet Information Services (IIS)
Open IIS. In the left pane under ‘Sites’, select the Web site or application that you want to redirect from.
Double click on ‘HTTP Redirect’ in the main pane under the ‘IIS’ section:
If the HTTP Redirect feature is missing from the pane, you will need to turn it on by opening ‘Turn Windows features on or off’ and navigating to ‘Internet Information Services’ -> ‘World Wide Web Servies’ -> ‘Common HTTP Features’ and selecting the checkbox for ‘HTTP Redirection’:
Check the checkbox for ‘Redirect requests to this destination:’ and enter the URL to redirect to.
You can also check the checkbox for ‘Redirect all requests to exact destination’ under ‘Redirect Behavior’ if you want all sub folders and files to redirect to the URL.
Once done, click on ‘Apply’ under ‘Actions’ on the right hand pane to start the redirection.