Install-WindowsFeatureIis

Installs IIS if it isn't already installed.

Syntax

Install-WindowsFeatureIis [-HttpRedirection] [<CommonParameters>]

Description

This function installs IIS and, optionally, the IIS HTTP redirection feature. If a feature is already installed, nothing happens.

NOTE: This function is only available on operating systems that have servermanagercmd.exe or ocsetup.exe and WMI support for the Win32_OptionalFeature class.

Parameters

Name Type Description Required? Pipeline Input Default Value
HttpRedirection SwitchParameter Install IIS's HTTP redirection feature. false false

EXAMPLE 1

Install-WindowsFeatureIis

Installs IIS if it isn't already installed.

EXAMPLE 2

Install-WindowsFeatureIis

Installs IIS and its HTTP redirection feature, if they aren't already installed.