Installation, updates, general problem solving and assistance.
User avatar
!
25%
Posts: 2539
Joined: 2013-02-25 18:36

2015-12-11 19:32 »

How to HTTP (URL) redirect in IIS without losing the query string parameters.

It is needed if you change your main domain to something else or for example if you ran your domain without SSL and now you want everything to get redirected into the SSL without killing off your old links.

Add "$S$Q" in the end of your redirect URL without any spaces (http://www.yourredirectdomain.com$S$Q) and mark the checkbox "Redirect all requests to exact destination (instead of relative to destination) and status code "Permanent (301)".

Like this:

IIS URL redirect keeping parameters 0.png
IIS URL redirect keeping parameters 0.png (72.31 KiB) Viewed 1248 times

IIS URL redirect keeping parameters.png
IIS URL redirect keeping parameters.png (14.45 KiB) Viewed 1248 times