Set-SPWebApplication

Configures the specified Web application.

Syntax

Set-SPWebApplication
   [-Identity] <SPWebApplicationPipeBind>
   [-OutgoingEmailAddress <String>]
   [-ReplyToEmailAddress <String>]
   -SMTPServer <String>
   [-AssignmentCollection <SPAssignmentCollection>]
   [-Confirm]
   [-Force]
   [-WhatIf]
   [-DisableSMTPEncryption]
   [-NotProvisionGlobally]
   [-SMTPServerPort <Int32>]
   [<CommonParameters>]
Set-SPWebApplication
   [-Identity] <SPWebApplicationPipeBind>
   -Zone <SPUrlZone>
   [-AdditionalClaimProvider <SPClaimProviderPipeBind[]>]
   [-AssignmentCollection <SPAssignmentCollection>]
   [-AuthenticationMethod <String>]
   [-AuthenticationProvider <SPAuthenticationProviderPipeBind[]>]
   [-Confirm]
   [-Force]
   [-SignInRedirectProvider <SPTrustedIdentityTokenIssuerPipeBind>]
   [-SignInRedirectURL <String>]
   [-WhatIf]
   [-NotProvisionGlobally]
   [<CommonParameters>]
Set-SPWebApplication
   [-Identity] <SPWebApplicationPipeBind>
   [-AssignmentCollection <SPAssignmentCollection>]
   [-Confirm]
   [-DefaultQuotaTemplate <String>]
   [-DefaultTimeZone <Int32>]
   [-Force]
   [-ServiceApplicationProxyGroup <SPServiceApplicationProxyGroupPipeBind>]
   [-WhatIf]
   [-NotProvisionGlobally]
   [<CommonParameters>]

Description

This cmdlet contains more than one parameter set. You may only use parameters from one parameter set and you may not combine parameters from different parameter sets. For more information about how to use parameter sets, see Cmdlet parameter sets.

The Set-SPWebApplication cmdlet configures the Web application specified by the Identity parameter. For any settings that are zone-specific (for the Zone parameter set), the zone to configure must be provided. The provided zone must already exist.

For permissions and the most current information about Windows PowerShell for SharePoint Products, see the online documentation at SharePoint Server Cmdlets.

Examples

EXAMPLE

$ap = New-SPAuthenticationProvider -AllowAnonymous
Set-SPWebApplication http://somesite -Zone "Extranet" -HostHeader "http://www.contoso.com" -AuthenticationProvider $ap

This example sets the HostHeader URL for the Extranet zone of the given Web application as http://www.contoso.com and enables anonymous access.

Parameters

-AdditionalClaimProvider

Adds a specific claim provider to the defined Web application.

Type:SPClaimProviderPipeBind[]
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False
Applies to:SharePoint Server 2010, SharePoint Server 2013, SharePoint Server 2016, SharePoint Server 2019

-AssignmentCollection

Manages objects for the purpose of proper disposal. Use of objects, such as SPWeb or SPSite, can use large amounts of memory and use of these objects in Windows PowerShell scripts requires proper memory management. Using the SPAssignment object, you can assign objects to a variable and dispose of the objects after they are needed to free up memory. When SPWeb, SPSite, or SPSiteAdministration objects are used, the objects are automatically disposed of if an assignment collection or the Global parameter is not used.

When the Global parameter is used, all objects are contained in the global store. If objects are not immediately used, or disposed of by using the Stop-SPAssignment command, an out-of-memory scenario can occur.

Type:SPAssignmentCollection
Position:Named
Default value:None
Required:False
Accept pipeline input:True
Accept wildcard characters:False
Applies to:SharePoint Server 2010, SharePoint Server 2013, SharePoint Server 2016, SharePoint Server 2019

-AuthenticationMethod

Use to set a Web application to classic Windows authentication. The valid values are NTLM or Kerberos.

Type:String
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False
Applies to:SharePoint Server 2010, SharePoint Server 2013, SharePoint Server 2016, SharePoint Server 2019

-AuthenticationProvider

Defines the authentication provider(s) that applies to the Web application.

Type:SPAuthenticationProviderPipeBind[]
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False
Applies to:SharePoint Server 2010, SharePoint Server 2013, SharePoint Server 2016, SharePoint Server 2019

-Confirm

Prompts you for confirmation before executing the command. For more information, type the following command: get-help about_commonparameters

Type:SwitchParameter
Aliases:cf
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False
Applies to:SharePoint Server 2010, SharePoint Server 2013, SharePoint Server 2016, SharePoint Server 2019

-DefaultQuotaTemplate

Specifies the new default site quota template for this Web application.

Type:String
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False
Applies to:SharePoint Server 2010, SharePoint Server 2013, SharePoint Server 2016, SharePoint Server 2019

-DefaultTimeZone

Specifies the default time zone for new site collections in this Web application.

Type:Int32
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False
Applies to:SharePoint Server 2010, SharePoint Server 2013, SharePoint Server 2016, SharePoint Server 2019

-DisableSMTPEncryption

{{Fill DisableSMTPEncryption Description}}

Type:SwitchParameter
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False
Applies to:SharePoint Server 2016, SharePoint Server 2019

-Force

Suppresses confirmation messages involved in settings for a Web application.

Type:SwitchParameter
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False
Applies to:SharePoint Server 2010, SharePoint Server 2013, SharePoint Server 2016, SharePoint Server 2019

-Identity

Specifies the name or URL of the Web application.

The type must be a valid name, in the form WebApplication-1212, or URL, in the form http://server_name/WebApplicaiton-1212.

Type:SPWebApplicationPipeBind
Position:1
Default value:None
Required:True
Accept pipeline input:True
Accept wildcard characters:False
Applies to:SharePoint Server 2010, SharePoint Server 2013, SharePoint Server 2016, SharePoint Server 2019

-NotProvisionGlobally

{{Fill NotProvisionGlobally Description}}

Type:SwitchParameter
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False
Applies to:SharePoint Server 2016, SharePoint Server 2019

-OutgoingEmailAddress

Specifies the new outgoing e-mail address for e-mail messages sent from this Web application. The type must be a valid address; for example, someone@example.com.

Type:String
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False
Applies to:SharePoint Server 2010, SharePoint Server 2013, SharePoint Server 2016, SharePoint Server 2019

-ReplyToEmailAddress

Configures the reply e-mail address.

The type must be a valid address; for example, someone@example.com.

Type:String
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False
Applies to:SharePoint Server 2010, SharePoint Server 2013, SharePoint Server 2016, SharePoint Server 2019

-ServiceApplicationProxyGroup

Specifies a custom service application proxy group for the Web application to use. The Web application will use the proxies in this proxy group to connect to service applications. If this parameter is not specified, the farm's default proxy group is used.

Type:SPServiceApplicationProxyGroupPipeBind
Aliases:ProxyGroup
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False
Applies to:SharePoint Server 2010, SharePoint Server 2013, SharePoint Server 2016, SharePoint Server 2019

-SignInRedirectProvider

Sets the sign-in redirect URL to point to the URL that is defined in the specified authentication provider.

Type:SPTrustedIdentityTokenIssuerPipeBind
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False
Applies to:SharePoint Server 2010, SharePoint Server 2013, SharePoint Server 2016, SharePoint Server 2019

-SignInRedirectURL

Specifies the sign-in redirect URL for the Web application.

Type:String
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False
Applies to:SharePoint Server 2010, SharePoint Server 2013, SharePoint Server 2016, SharePoint Server 2019

-SMTPServer

Specifies the new outbound SMTP server that this Web application will use.

Type:String
Position:Named
Default value:None
Required:True
Accept pipeline input:False
Accept wildcard characters:False
Applies to:SharePoint Server 2010, SharePoint Server 2013, SharePoint Server 2016, SharePoint Server 2019

-SMTPServerPort

{{Fill SMTPServerPort Description}}

Type:Int32
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False
Applies to:SharePoint Server 2016, SharePoint Server 2019

-WhatIf

Displays a message that describes the effect of the command instead of executing the command. For more information, type the following command: get-help about_commonparameters

Type:SwitchParameter
Aliases:wi
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False
Applies to:SharePoint Server 2010, SharePoint Server 2013, SharePoint Server 2016, SharePoint Server 2019

-Zone

When configuring zone-specific settings, the zone to configure must be specified. This zone must already exist.

The type must be any one of the following values: Default, Intranet, Internet, Extranet, or Custom.

Type:SPUrlZone
Position:Named
Default value:None
Required:True
Accept pipeline input:False
Accept wildcard characters:False
Applies to:SharePoint Server 2010, SharePoint Server 2013, SharePoint Server 2016, SharePoint Server 2019