How can I create a template for SharePoint that shows up under the "From Your Organization" when choosing a template for a new site you're creating?

How can I create a template for SharePoint that shows up under the "From Your Organization" when choosing a template for a new site you're creating? I have figured out how to use PowerShell to apply an existing site's "look" as a template on already created sites. However, I haven't found a way to create a site with a custom template already applied. If anyone knows how to add a custom template to this "From Your Organization" section, please let me know!

I've included a screenshot of what I am referring to:

Dear Kaelie,

To create a custom site template, you may use the site script in JSON. You can use Power Automate or PowerShell to apply it.

Here is an example to apply the example script in Get started creating SharePoint site templates and site scripts | Microsoft Learn to the site in our environment with Power Automate.

I name this template as sitetemplate1 in Power Automate.

ImageImageImage

.

Create the site script.

Method: POST

Uri: /_api/Microsoft.SharePoint.Utilities.WebTemplateExtensions.SiteScriptUtility.CreateSiteScript(Title='sitetemplate1')

Headers:

{

"Content-Type\n": "application/json;charset=utf-8",

"accept": "application/json;odata.metadata=minimal",

"odata-version": "4.0"

}

Initialize variable 2: outputs('Send_an_HTTP_request_to_SharePoint')?['body']?['Id']

Add the site template to the site.

Method: POST

Uri: /_api/Microsoft.SharePoint.Utilities.WebTemplateExtensions.SiteScriptUtility.CreateSiteDesign

Headers:

{

"Content-Type\n": "application/json;charset=utf-8",

"accept": "application/json;odata.metadata=minimal",

"odata-version": "4.0"

}

Body:

{ "info": { "Title": "sitetemplate1", "Description": "sitetemplate1", "SiteScriptIds": ["@{variables('ScriptID')}"], "WebTemplate": "64" } }

Result:

.

You can also use PowerShell to create and add it by the steps in Get started creating SharePoint site templates and site scripts | Microsoft Learn.


Thank you for your effort and time.

Sincerely

Cliff | Microsoft Community Moderator

Beware of Scammers posting fake Support Numbers here.

1 person found this reply helpful

·

Was this reply helpful?

Sorry this didn't help.

Great! Thanks for your feedback.

How satisfied are you with this reply?

Thanks for your feedback, it helps us improve the site.

How satisfied are you with this reply?

Thanks for your feedback.

Dear Kaelie,

Do you need further help on this issue?

Welcome to share any updates at your convenience if you need further help on this issue.

Thank you for your effort and time.

Sincerely

Cliff | Microsoft Community Moderator

Beware of Scammers posting fake Support Numbers here.

Was this reply helpful?

Sorry this didn't help.

Great! Thanks for your feedback.

How satisfied are you with this reply?

Thanks for your feedback, it helps us improve the site.

How satisfied are you with this reply?

Thanks for your feedback.

 
 

Question Info


Last updated December 2, 2024 Views 1,203 Applies to: