Save publishing site as a template

Info: SharePoint Designer is required in order to accomplish the steps described in this article. If you need to download it please follow this link

Save site as a template is disabled by default in Publishing sites and Collaboration sites with the publishing features active. In this article we explain all the steps to bring back the site template functionality.

  1. Open the site with SharePoint designer
  2. In the ribbon go to Site Options
  3. Locate the options SaveSiteAsTemplateEnabled and modify the value to true
  4. Since the site template is disabled in the Publishing sites the option Save Site as Template is not available in the Site Settings you will need to navigate to the page directly:
  5. Provide all the details and click OK after a couple of minutes you will have the WSP site template generated

    If the operation succeeds you will see the screen bellow

    Note: If you have apps downloaded from the store they could prevent you to save the site as a template if you are facing this scenario you will need to uninstall the apps first.

  6. Open the solution gallery and click in the template name to download the wsp file containing the site template

Create a site based on the new template

  1. Open the site collection where you want to install the site template. If you have other sandbox solutions installed in the original site collection you will need to install them first in the new site collection
  2. Open the solution gallery to upload and activate the site template wsp
  3. Go to Site Contents and create a new subsite
  4. Provide all the details and select Custom in the Select a template option
  5. Select the template name and click Create, it may take a few minutes

    If the site creation fails, you will see an error message like this one and you will need to activate the missing features. Bellow you have the steps to activate all the required features.

Activate missing features

Most of the missing features can be activated in the Manage Site Collection features and to do that you have a graphical interface in the site settings. If the required feature is not available in the list, you can follow the steps bellow.

Office 365

You can activate features from SharePoint Online using a PowerShell script, the script and the required dll files can be downloaded from here.

    1. Extract the files from the zip
    2. Edit the PS1 file
    3. Modify the variables to connect to your SharePoint

      $sUserName: User Name to connect to the SharePoint Online Site Collection.

      $sPassword: Password for the user.

      $sSiteColUrl: SharePoint Online Site Collection

      $sFeatureGuid: GUID of the feature to be enabled

    4. Run the script
    5. After all features have been activated you will be able to create your custom site

SharePoint 2013

    1. On the SharePoint server open the command line as Administrator
    2. Type the following command cd C:\Program Files\Common Files\Microsoft Shared\Web Server Extensions\15\BIN"
    3. Type the following command stsadm -o activatefeature -id <feature-guid> -url <site-collection-url>

      Replace the <feature-guid> by the feature ID, depending of your SharePoint version it can be presented as a correlation ID.

      Replace the <site-collection-url> by the site collection url where you want to activate the feature

    4. After all features have been activated you will be able to create your custom site
Have more questions? Submit a request


Powered by Zendesk