Save Modern Team Site as a template & provision using Classic Team Site method (visible in SP Admin)

Copper Contributor

You can save a Modern Team Site (the Team Site that gets provisioned when you provision an Office 365 Group / Unified Group) as a template, then using the "Classic Team Site" provisioning process (SharePoint Admin Centre, Site Collections) you can provision Modern Team Sites from this template.  Modern Team Sites provisioned in this way appear in the Classic Team Sites world, so to speak, so they are visible in SP Admin Centre.  They are also all linked to the same Office 365 / Unified Group.  The "Group conversations" link on the home page of all of them points back to the same Outlook Office 365 Group.  So you now have a one-to-many relationship between one Office 365 / Unified Group and many Modern Team Sites.  They are fully featured Modern Team Sites i.e. they're not just classic Team Sites with the "modern UI" skinned on top.  This is quite handy for a scenario I'm working on.  The detailed steps are below.

 

My question is:  Even though the steps are all "legitmate" i.e. supported, is doing this actually supported by Microsoft?

 

Detailed steps below ...

 

How to save the team site of an Office 365 Group (Unified Group) as a template, and create sites via the "classic" provisioning process from that template

Create a Unified Group with associated team site.  This team site will be used as the source for the site template.

Navigate to team site, Site Settings (Site information, View all site settings), notice Save site as template is missing.

Notice that appending _layouts/savetmpl.aspx to the URL doesn't work, you get "Sorry, you don't have access to this page".

This is due to scripting being disabled in the Unified Group team site, which over-rides the SharePoint Admin Centre, Settings, Custom Script, configuration.

To enable the scripting for the site, per this article, …

 

https://support.office.com/en-us/article/Allow-or-prevent-custom-script-1f2c515f-5d7e-448a-9fd7-835d...

 

… run the following PowerShell …

 

# Import general SPO module and connect

Import-Module Microsoft.Online.SharePoint.PowerShell -DisableNameChecking

Connect-SPOService -Url https://yourname-admin.sharepoint.com/

 

Set-SPOsite "https://yourname.sharepoint.com/sites/yoursite" -DenyAddAndCustomizePages 0

 

Return to the Unified Group team site, Site Settings, notice Save site as template is now available.

Click Save as a template and save the site as a template.

Go to Site Settings (Site information, View all site settings), Web Designer Galleries, Solutions.

Notice the site template you just saved, click the file, Save the .wsp file locally.

Go to SharePoint Admin Centre, site collections, New, Private Site Collection, and create a site collection using Custom, <Select template later… > .

Go to the home page of the new site collection, in the Template Selection choose Solution Gallery.

In the Solution Gallery click Upload Solution, browse locally and select the .wsp file you just downloaded.

Click Activate to activate the template solution.

Return to the home page of the new site collection, the Template Selection is displayed again.

Select Custom, then your template you just uploaded.

Use the default SP groups for the site's groups setup.

 

So this new site collection has the following properties: -

 

  1. The home page is a genuine Unified Group team site home page, because it is based on a template that was a Unified Group team site.
  2. The site collection appears in SharePoint Admin, Settings, site collections, because it was provisioned using the "classic" site collection provisioning process.
  3. None of the steps performed are "unsupported" by Microsoft.  There was no "copy-and-paste" of the _layouts/savetmpl.aspx URL (as, for example, can be performed to save Publishing Sites as a template and thereby render them unsupported by Microsoft).  Microsoft technical support confirmed this.
  4. The site is linked into the Unified Group that is associated with the source site of the template.  Clicking on "Group Conversations" on the home page of the newly created site takes you into Outlook positioned on the Unified Group associated with the source of the template.  So now instead of a 1-to-1 relationship between the Unified Group and the Site, it is 1-to-many.
  5. If you create sub-sites using the template, in either the source site or any site created from the template, these behave similarly i.e. all have the relevant properties 1, 3-4 above.
14 Replies
In general avoid to use the Save as template feature in SPO and go to the work being done by the PnP Project Team...if you ask my opinion, you are just saving a site as template but as I have said, this is not the way to currently provision sites in SPO based on templates

Yes, that's a very valid pointer.

 

The issue for me was that the PnP provisioning process seems only to be able to create Unfied Groups with a Modern Team Site, or, Classic Team Sites.  The MTS is all bound up with the UG on a 1-to-1 basis and not visible in SP Admin Centre etc. etc.  The CTS is disconnected from any UG and not fully featured with all the "modern" capabilities, only some of them being available.

 

What I wanted was one UG with two MTS's bound to it.  Creating a sub-site in the one MTS of a UG might have been an option but for the fact that sub-sites are not full-on "modern" (yet).  Also, the second site was to have its own site collection admin i.e. the site collection admin of the first site should not be able to manage permissions on the second, and vice versa.

 

I also wanted the consistency in the user experience of having only MTS's, not a mixture of MTS's and CTS's (I mean, who wouldn't want this!?).  So for the sites that are to be provisioned as standalone Team Sites with no UG attached to them, I wanted them to be MTS's - like the sites bound up with the UG.

 

So far I haven't found anything in PnP that can achieve these requirements - and I'd be very pleased if someone to show me!

 

The only process that seems to work is the good ol' "Save Site as a Template" as described above.  But my worry is that MS are frowning on this, as you highlighted.

 

If MS is frowning on it so much that it is unsupported, then I'll just have to pause the project and wait until the roadmap of UG, MTS, and CTS reveals itself in deliverables.

 

If the MS frown is not that it is unsupported, but "not best practice", then until the "best practice" comes along by way of the roadmap delivering a consistent usage of MTS's across UG's and standalones together with supporting PnP provisioing processes, I'll stick with "Save Site as a Template" and migrate to "best practice" later when it's available.

 

So the question to MS still stands:  Is using the "Save Site as a Template" process described above, to template the UG MTS and redeploy it into the "traditional" CTS world (visible in SP Admin Centre, etc.), a supported process?

 

And an additonal question now:  Is there a PnP way of templating an MTS from the UG world, and deploying it out as a standalone site in the "traditional" CTS world (visible in SP Admin Centre, etc.)?

Hi Lawrence,

hi Community,

we are facing the same demands and thoughts. And as "per now" i would follow this Approach to achieve our objectives in short Terms.

But is there any other eligible, PnP-process in sight that solves this Job?

Thankful for any thoughts regarding this.

Thanks, Ulrich

Thanks for the article.

I follow the same steps on different tenant. Everything is working fine apart from "Group conversations" link. How to resolve this?

Just to be clear. Using save-site-as-a-template with modern team sites or publishing sites is NOT supported. You can always find aways with tenant admin permissions to achieve things, but the fact that it's doable does not mean it's supported.

 

Any sites created with the template which has been produced with this method can have unexpected issues in the future, so provided steps should never be used.

 

Best regards,

Vesa Juvonen, Senior Program Manager, SharePoint Engineering, Microsoft.

I have created a blog around this issue. But be aware PnP would be you best practice:

https://sharepoint-specialist.nu/save-list-as-template-on-modern-team-site-not-available-in-sharepoi...

"You can always find ways with tenant admin permissions to achieve things, but the fact that it's doable does not mean it's supported."

 

Indeed.  So much so that even Microsoft support tell you you can do things that aren't supported.

 

What does it say about a product and its vendor that such a statement is so proudly and positively announced?

 

"Our product so lacks integrity that you can configure it in ways that appear perfectly legitimate, but does in fact mean that the system state integrity is broken and deployment corrupted."

 

An accounting package which allows you to make transactions where the debits don't equal the credits.  A nuclear power-station where a sequence of button presses leads to meltdown, and the support team tells you "If you can do it through the UI or PowerShell, it's ok".

 

Once all the re-writes of the dysfunctional SharePoint slap-on services have been completed as new products outside of SP, with their own MS development teams with some actual staff and some sort of future ...

 

SP Workflow -> Flow

IP Forms, Access Services -> PowerApps

Task Lists -> Planner

Lists, Columns, Metadata -> Common Data Service

BCS -> Connections, Data Sources, Data Management Gateway

Search -> Delve

SP Social -> Teams

 

... could Microsoft please ditch what remains, that is: a third rate cloud-based file system dogpile called SharePoint / OneDrive, and buy Dropbox and integrate it in?

@Vesa Juvonen Would you by any chance know if it will become possible (and supported) to create your own site collection templates and use them when creating a new site collection - SharePoint Online only?

I have googled around and I am not really able to find a solution. I am not a developer, and even though I can create and use PowerShell scripts, I would rather be able to use an "old fashion" UI :) like the "save site as template".

Or do you know for sure that using a custom template for site collection creation will never really be an option?

Thanks in advance :)

@Vesa Juvonen 

 

Can you propose an alternative way on how to use created team sites as a template (e.g. for project management this would be really helpfull). If you could just add a new predefined project team site (e.g. with lists of risks, issues etc) whenever you have a new project. 

 

Thanks for the answer. 

@Vesa Juvonen 

 

What is the correct, support way to create Site templates? I have many sites (all the same layout) that will need building very soon. As it stands I will have to create every single site by hand? Very inefficient. To read that 'Save as Template' was once a thing but now unavailable and unsupported sounds crazy to me.  Especially when a lot of emphasis is being put on Power Automate, and business automation.

@RobOnyxPublishing 

 

As mentioned in this thread - classic "Save site as as template" which was introduced back in 2008 will not work for modern sites. This is by design. You can however use for example PnP PowerShell to export and import sites with the tenant template capability, which also look book site at httts://lookbook.microsoft.com is using.

 

If you need to replicate similar sites, using PowerShell is definitely the most efficient way to do that.

@Vesa Juvonen 

 

Thank you. I am new to the MS eco system. So powershell is also very new to me. Is there any documentation I can follow to achieve this?

 

And do you know if it is possible to then use Power Automate to automate the creation of a Team site using the template? and then create the MS Team from this? As we constantly have projects going live, all with the same template. To Be able to automate this process is another step in allowing the company to scale. 

 

Many thanks