Create a Site Under a Site Collection

Scenario/Problem: You want to create sites under your site collection.

Solution: Use the New-SPWeb cmdlet.

To add a new subsite, use the New-SPWeb cmdlet as follows:

New-SPWeb -url <full url of new site> -name <name of new site>-template <site template to use>

The following switch parameters are available when using the New-SPWeb cmdlet:

AddToTopNav

UniquePermissions

UseParentTopNav

The AddToTopNav switch parameter places the new site within the top navigation of the site collection. Using the UseParentTopNav switch parameter replicates the top nav of the site collection onto the new subsite. Creating a site with UniquePermissions forces the site to not inherit permissions from the site collection ...

Get PowerShell™ for SharePoint® 2013 How-To now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.