Export (0) Print
Expand All

Add an ISAPI Filter (IIS 7)


Add an ISAPI filter when you want to enhance Web server functionality. For example, you might have an ISAPI filter that captures information about HTTP requests and saves the information to a database.

Although IIS 7 supports ISAPI filters, we recommend that you extend Web server functionality by using modules instead of by using ISAPI filters. For more information, see Configuring Modules in IIS 7.

You can add an ISAPI filters at the server level and the site level. If you add the ISAPI filter at the server level, the filter will intercept all requests made to the server. If you add the ISAPI filter to a specific site, the filter will intercept all requests made to that site.

For information about the levels at which you can perform this procedure, and the modules, handlers, and permissions that are required to perform this procedure, see ISAPI Filters Feature Requirements (IIS 7).

Exceptions to feature requirements

  • None



  2. In Features View, on the server or siteHome page, double-click ISAPI Filters.

  3. On the ISAPI Filters page, in the Actions pane, click Add.

  4. In the Add ISAPI Filter dialog box:

    • In the Filter name box, type a friendly name for the ISAPI filter.

    • In the Executable box, type the file system path of the location of ISAPI filter file, or click the browse button (...) to navigate to the folder that contains the ISAPI filter file.

  5. Click OK.

To add an ISAPI filter, use the following syntax:

appcmd set config /section:isapiFilters /+[name=' string ',path=' string ',enabled='true|false',enableCache='true|false',preCondition='string']

The variable namestring is the name of the ISAPI filter that you want to add. The variable pathstring is the physical path of the ISAPI filter's .dll file.

Additionally, you can specify values for the optional attributes: enabled, enableCache, and preCondition. By default, the enabled attribute is true, the enableCache attribute is false, and there are no preconditions. If you want to disable the ISAPI filter, specify false for the enabled attribute. If your ISAPI filter is cache friendly to HTTP.sys, which means that the filter does not conditionally reroute URLs for /default.htm to either /default-1.htm or /default-2.htm, you can specify true for the enableCache attribute. Finally, you can include preconditions if your ISAPI filter has certain conditions under which it should run, such as the bitness32 precondition, which specifies that an ISAPI filter should run only in 32-bit worker processes.

For example, to add an ISAPI filter named ResponseFilter, with a .dll file in the .NET Framework version 2.0 directory and a precondition to run only in 32-bit worker processes, type the following at the command prompt, and then press ENTER:

appcmd set config /section:isapiFilters /+[name=' ResponseFilter ',path='%windir%\Microsoft.NET\Framework\v2.0.50727\ responseFilter .dll',preCondition='bitness32']


The procedure in this topic affects the following configuration elements:




  • IsapiFiltersSection.Filters.Add method


See Also

Was this page helpful?
(1500 characters remaining)
Thank you for your feedback

Community Additions

© 2014 Microsoft