Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

We're about to do some major maintanence on an IIS 6 / ASP (Classic) website. We want all visitors to be redirected to a "Coming Soon" page (or something similar). This should NOT apply to our dev team (operating remotely), so we'd want to specify certain IPs that should have access to the under-construction site.

How can this be accomplished in IIS 6? (Using classic ASP if needed)

share|improve this question
up vote 6 down vote accepted

To do this without modifying any code, an alternative is in IIS6 do the following:

  1. Deny access to all ip addresses except those of your developers
    (in IIS6 Manager, go to the web directory -> properties -> Directory Security -> "IP address and domain name restrictions"

  2. Change the error response for http error 403.6 to point to your "Coming Soon" static html page.
    (In IIS6 Manager go to the web directory -> properties -> "Custom Errors" -> click on the row for "403;6" and edit the location to point to your html file.)

Important: Your html page must be large enough or many versions of Internet Explorer will display their so-called "friendly" error message instead of your content. I believe the threshold is that it must be larger than 512 bytes. See:;en-us;Q294807

share|improve this answer
A very creative solution, excellent idea. – Jon Angliss Jun 15 '10 at 2:14
Perfect - thank you! – Colin O'Dell Jul 13 '10 at 18:27

Creade a default.asp page with code similar to the following:

<% IF Request.ServerVariables("REMOTE_ADDR") = special_ip_address THEN
  END IF %>
share|improve this answer
This would work great for all direct traffic to the homepage, but what about traffic to other pages? – Colin O'Dell Sep 19 '09 at 8:02
No solution for that. AFAIK, IIS can show different sites if it is asked for different host headers and/or different IPs, but it can't do different things based on the client IP. Unless you put an ISAPI filter in the middle... – Massimo Sep 19 '09 at 12:41
You could use Massimo's code in global.asa in the Script_OnStart section. Just have it redirect them to another site that you setup since this is only fired once per session and you don't want them navigating back after the first try. (IIRC Classic ASP doesn't have an event handler that is fired on every request). The other limitation is that this doesn't address non-ASP pages. The ideal way to do this in IIS6 is with an ISAPI filter like ISAPI Rewrite ( That can do exactly what you need. – Scott Forsyth - MVP Sep 20 '09 at 22:07

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.