[Fixed] Why You Cannot Save Site as Template in SharePoint

Written By Shubrato

SharePoint, Microsoft’s powerful collaboration and document management platform, offers a multitude of features to simplify workflows and enhance productivity.

But Among these vast features and functionalities, there exists an unusual limitation that has puzzled users — the inability to save a site as a template.

why-you-cannot-save-site-as-template-in-sharepoint

In this article, I’ll delve into the reasons why you can’t save your SharePoint site as a template and provide the solutions to those issues.

Let’s begin!

Why are You Unable to Save a Site as a Template in SharePoint Online or SharePoint Server?

It is not possible to save a site as a template in SharePoint Online if you are attempting to create a template from a Communication Site. This limitation also arises when publishing features are enabled and the custom script is not allowed at the tenant level.

Below I’ve explained why you are unable to save a site as a template in SharePoint Online or SharePoint Server. Let’s see.

Trying to Create a Template from a Communication Site

In SharePoint, the ability to create site templates is limited to classic sites or modern team sites that are not associated with an Office 365 Group. Unfortunately, the feature is not available on communication sites.create-a-template

So, you can save existing classic sites or standalone modern team sites as templates for creating new sites and preserving their structure, layout, and content.

However, if you wish to replicate the design and configuration of a communication site, you will have to manually recreate it.

Publishing Features are Enabled

One of the primary reasons why the Save site as template option is disabled in SharePoint is when you’ve enabled publishing features. It is a common scenario that many users encounter.

At the time of creating a site group, it’s typically configured for collaboration by default, with a focus on web parts, libraries, and lists for teams. Specific features and capabilities within SharePoint require the site collection to be transformed into a publishing hub.

So, enabling publishing features are necessary to unlock these advanced functionalities. Unfortunately, as a consequence, you are unable to create custom site templates to ensure the integrity and consistency of the publishing infrastructure.

Custom Script is Not Allowed at the Tenant Level

Another reason the Save site as template option is not showing up in Site settings is the restriction on running custom scripts at the tenant level.

When you set up a new Office 365 tenant, SharePoint has a default configuration that stops the custom scripts from running for advanced coding customization.

Though this security measure ensures a controlled environment, it disables several features, including Web Designer Galleries and the ability to save custom site templates.

These limitations aim to mitigate potential security risks and ensure the stability and integrity of the SharePoint environment. But they can impact the availability of certain functionalities for customization purposes.

How to Fix Save Site as Template Option Missing in SharePoint Online

To enable the Save site as template feature in SharePoint, first, turn off the SharePoint Server Publishing Infrastructure from Site settings. Then try saving the site template by directly opening the template creation page URL. Also, use PowerShell commands to unlock the template saving option.

Follow the instructions below to enable save site as a template in SharePoint:

1. Deactivate SharePoint Server Publishing Infrastructure

This feature is typically enabled by default on publishing sites and needs to be turned off before saving the site as a template.

Here are the steps to deactivate the SharePoint server publishing infrastructure:

  • Open Microsoft 365 and log in to your account.
  • Select the App launcher from the top right and choose SharePoint.app-launcher-sharepoint
  • Open the team site for which you want to create a template.
  • Go to the Site contents tab from the left bar and choose Site settings.sharepoint-site-settings
  • Select Site collection features from the Site Collection Administration section.sharepoint-site-collection-features
  • Scroll down to the SharePoint Server Publishing Infrastructure option and click the Deactivate button.sharepoint-publishing-infrastructure-deactivate
  • Select Deactivate this feature.sharepoint-publishing-infrastructure-deactivate-feature

2. Use the Save Site as Template URL

SharePoint provides a URL that allows you to save the site as a template. You can access this URL by appending “/_layouts/15/savetmpl.aspx” to your site’s URL.

Below I’ve provided the steps to use the Save as template URL:

  • Open your SharePoint site from which you want to construct a template.
  • Remove the last part of the site URL, replace it with savetmpl.aspx, and press Enter.

3. Enable Save Site as Template using PowerShell

PowerShell is a command-line scripting language that allows you to automate various tasks in SharePoint. By using specific PowerShell commands, you can enable the Save site as template functionality.

Here’s the process to enable a custom site template using PowerShell:

  • Search for PowerShell and open it as an administrator.powershell-run-as-admin
  • Run the following command to establish a link to your SharePoint Online account:
Connect-SPOService

sharepoint-connect-powershell

  • Copy your SharePoint admin center URL, paste it into PowerShell, and press Enter.
  • Provide your admin credentials to sign in to the Microsoft 365 account, and it’ll connect to PowerShell.sharepoint-admin-connect-powershell
  • Execute the command below to open the feature list of your SharePoint site:
Get-SPOSite -identity “URL of your site” | fl
  • Check the DenyAddAndCustomizePages option. If it is enabled, you cannot save your site as a template, and you must disable it.
    sharepoint-site-feature-list
  • Run the script I’ve given below to turn off DenyAddAndCustomizePages:
Get-SPOSite -identity “Your site URL” -DenyAddAndCustomizePages $false
  • Execute the command below to check the feature list of your site once again and see whether the DenyAddAndCustomizePages option is changed to Disabled:
Get-SPOSite -identity “URL of your site” | fl

Once you’ve turned off DenyAddAndCustomizePages, open your SharePoint team site from which you want to create a template. Go to Site setting, select Save site as template, and construct your template.

FAQs

Can I save a SharePoint site as a template?

Yes, you can save a SharePoint site as a template. To do that, open the SharePoint site for which you want to create a template. Remember, it has to be a Team site. Go to Site settings, click Save site as template from the Site Actions section, and provide the template name in the File name text field.

How do I save a list as a template in SharePoint modern site?

To save a list as a template on SharePoint Online, make sure you have sufficient permissions. Navigate to the list settings and select the Save as Template option. Save the list as a template and upload it to the desired site. Now, you can easily create a new list based on the template, including its contents.

How do I save a workflow as a template in SharePoint?

To save a workflow as a template in SharePoint, go to the Workflow Settings tab, and click Save as Template in the Manage section. The template includes all settings, actions, and conditions. It can be shared with others for collaborative workflow creation.

Final Thoughts

The inability to save a site as a template in SharePoint can be frustrating for users trying to replicate or reuse their site configurations. Although SharePoint does not provide a direct solution to save a site as a template, some methods create consistent and reusable site templates.

By following the steps provided in this article, you can effectively address the challenge of saving sites as templates.

Comment below if you have further questions, and we’ll get back to you soon.

About The Author
Shubrato is passionate about technology. From his core, he is a tech geek and can fix any tech-related issues through intensive research. He has an undergrad degree in Computer Science and Engineering. Besides being a tech enthusiast, Shubrato is passionate about capturing time in a frame and loves cycling.

Leave a Comment