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.

Get-SPWebApplication http://server | Set-SPWebApplication -Zone “Extranet” -HostHeader “” – AllowAnonymousAccess

This example sets the HostHeader URL for the Extranet zone of the given Web application as and enables anonymous access.