IIS AAR – URL Rewrite for reverse proxy – how to send HTTP_HOST

This post has the answer – Modifying headers with IIS7 Application Request Routing Need to enable preserveHostHeader – can’t see how you do that in the UI but this works Run this from command line to update Machine/webroot/apphost config %windir%\system32\inetsrv\appcmd.exe set config -section:system.webServer/proxy -preserveHostHeader:true /commit:apphost

URL Rewrite keeps original host Location when reverse proxy 301 redirects

Could Application Request Routing be involved? Look at IIS -> Machine or Site -> Application Request Routing Cache -> Server Proxy Settings and uncheck the “Reverse rewrite host in response headers” checkbox. If you do this at the machine level, it’ll take effect for all sites. If you do it on a particular site, it’ll … Read more